//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2022 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto-codegenerator.
// DO NOT EDIT.

import Foundation
import SotoCore

extension CloudFormation {
    // MARK: Enums

    public enum AccountFilterType: String, CustomStringConvertible, Codable, _SotoSendable {
        case difference = "DIFFERENCE"
        case intersection = "INTERSECTION"
        case none = "NONE"
        case union = "UNION"
        public var description: String { return self.rawValue }
    }

    public enum AccountGateStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case failed = "FAILED"
        case skipped = "SKIPPED"
        case succeeded = "SUCCEEDED"
        public var description: String { return self.rawValue }
    }

    public enum CallAs: String, CustomStringConvertible, Codable, _SotoSendable {
        case _self = "SELF"
        case delegatedAdmin = "DELEGATED_ADMIN"
        public var description: String { return self.rawValue }
    }

    public enum Capability: String, CustomStringConvertible, Codable, _SotoSendable {
        case capabilityAutoExpand = "CAPABILITY_AUTO_EXPAND"
        case capabilityIam = "CAPABILITY_IAM"
        case capabilityNamedIam = "CAPABILITY_NAMED_IAM"
        public var description: String { return self.rawValue }
    }

    public enum Category: String, CustomStringConvertible, Codable, _SotoSendable {
        case activated = "ACTIVATED"
        case awsTypes = "AWS_TYPES"
        case registered = "REGISTERED"
        case thirdParty = "THIRD_PARTY"
        public var description: String { return self.rawValue }
    }

    public enum ChangeAction: String, CustomStringConvertible, Codable, _SotoSendable {
        case `import` = "Import"
        case add = "Add"
        case dynamic = "Dynamic"
        case modify = "Modify"
        case remove = "Remove"
        public var description: String { return self.rawValue }
    }

    public enum ChangeSetHooksStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case planned = "PLANNED"
        case planning = "PLANNING"
        case unavailable = "UNAVAILABLE"
        public var description: String { return self.rawValue }
    }

    public enum ChangeSetStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case createComplete = "CREATE_COMPLETE"
        case createInProgress = "CREATE_IN_PROGRESS"
        case createPending = "CREATE_PENDING"
        case deleteComplete = "DELETE_COMPLETE"
        case deleteFailed = "DELETE_FAILED"
        case deleteInProgress = "DELETE_IN_PROGRESS"
        case deletePending = "DELETE_PENDING"
        case failed = "FAILED"
        public var description: String { return self.rawValue }
    }

    public enum ChangeSetType: String, CustomStringConvertible, Codable, _SotoSendable {
        case `import` = "IMPORT"
        case create = "CREATE"
        case update = "UPDATE"
        public var description: String { return self.rawValue }
    }

    public enum ChangeSource: String, CustomStringConvertible, Codable, _SotoSendable {
        case automatic = "Automatic"
        case directModification = "DirectModification"
        case parameterReference = "ParameterReference"
        case resourceAttribute = "ResourceAttribute"
        case resourceReference = "ResourceReference"
        public var description: String { return self.rawValue }
    }

    public enum ChangeType: String, CustomStringConvertible, Codable, _SotoSendable {
        case resource = "Resource"
        public var description: String { return self.rawValue }
    }

    public enum DeprecatedStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case deprecated = "DEPRECATED"
        case live = "LIVE"
        public var description: String { return self.rawValue }
    }

    public enum DifferenceType: String, CustomStringConvertible, Codable, _SotoSendable {
        case add = "ADD"
        case notEqual = "NOT_EQUAL"
        case remove = "REMOVE"
        public var description: String { return self.rawValue }
    }

    public enum EvaluationType: String, CustomStringConvertible, Codable, _SotoSendable {
        case `static` = "Static"
        case dynamic = "Dynamic"
        public var description: String { return self.rawValue }
    }

    public enum ExecutionStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case available = "AVAILABLE"
        case executeComplete = "EXECUTE_COMPLETE"
        case executeFailed = "EXECUTE_FAILED"
        case executeInProgress = "EXECUTE_IN_PROGRESS"
        case obsolete = "OBSOLETE"
        case unavailable = "UNAVAILABLE"
        public var description: String { return self.rawValue }
    }

    public enum HandlerErrorCode: String, CustomStringConvertible, Codable, _SotoSendable {
        case accessDenied = "AccessDenied"
        case alreadyExists = "AlreadyExists"
        case generalServiceException = "GeneralServiceException"
        case handlerInternalFailure = "HandlerInternalFailure"
        case internalFailure = "InternalFailure"
        case invalidCredentials = "InvalidCredentials"
        case invalidRequest = "InvalidRequest"
        case invalidTypeConfiguration = "InvalidTypeConfiguration"
        case networkFailure = "NetworkFailure"
        case nonCompliant = "NonCompliant"
        case notFound = "NotFound"
        case notUpdatable = "NotUpdatable"
        case resourceConflict = "ResourceConflict"
        case serviceInternalError = "ServiceInternalError"
        case serviceLimitExceeded = "ServiceLimitExceeded"
        case serviceTimeout = "NotStabilized"
        case throttling = "Throttling"
        case unknown = "Unknown"
        case unsupportedTarget = "UnsupportedTarget"
        public var description: String { return self.rawValue }
    }

    public enum HookFailureMode: String, CustomStringConvertible, Codable, _SotoSendable {
        case fail = "FAIL"
        case warn = "WARN"
        public var description: String { return self.rawValue }
    }

    public enum HookInvocationPoint: String, CustomStringConvertible, Codable, _SotoSendable {
        case preProvision = "PRE_PROVISION"
        public var description: String { return self.rawValue }
    }

    public enum HookStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case hookCompleteFailed = "HOOK_COMPLETE_FAILED"
        case hookCompleteSucceeded = "HOOK_COMPLETE_SUCCEEDED"
        case hookFailed = "HOOK_FAILED"
        case hookInProgress = "HOOK_IN_PROGRESS"
        public var description: String { return self.rawValue }
    }

    public enum HookTargetType: String, CustomStringConvertible, Codable, _SotoSendable {
        case resource = "RESOURCE"
        public var description: String { return self.rawValue }
    }

    public enum IdentityProvider: String, CustomStringConvertible, Codable, _SotoSendable {
        case awsMarketplace = "AWS_Marketplace"
        case bitbucket = "Bitbucket"
        case gitHub = "GitHub"
        public var description: String { return self.rawValue }
    }

    public enum OnFailure: String, CustomStringConvertible, Codable, _SotoSendable {
        case delete = "DELETE"
        case doNothing = "DO_NOTHING"
        case rollback = "ROLLBACK"
        public var description: String { return self.rawValue }
    }

    public enum OperationResultFilterName: String, CustomStringConvertible, Codable, _SotoSendable {
        case operationResultStatus = "OPERATION_RESULT_STATUS"
        public var description: String { return self.rawValue }
    }

    public enum OperationStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        case pending = "PENDING"
        case success = "SUCCESS"
        public var description: String { return self.rawValue }
    }

    public enum PermissionModels: String, CustomStringConvertible, Codable, _SotoSendable {
        case selfManaged = "SELF_MANAGED"
        case serviceManaged = "SERVICE_MANAGED"
        public var description: String { return self.rawValue }
    }

    public enum ProvisioningType: String, CustomStringConvertible, Codable, _SotoSendable {
        case fullyMutable = "FULLY_MUTABLE"
        case immutable = "IMMUTABLE"
        case nonProvisionable = "NON_PROVISIONABLE"
        public var description: String { return self.rawValue }
    }

    public enum PublisherStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case unverified = "UNVERIFIED"
        case verified = "VERIFIED"
        public var description: String { return self.rawValue }
    }

    public enum RegionConcurrencyType: String, CustomStringConvertible, Codable, _SotoSendable {
        case parallel = "PARALLEL"
        case sequential = "SEQUENTIAL"
        public var description: String { return self.rawValue }
    }

    public enum RegistrationStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case complete = "COMPLETE"
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        public var description: String { return self.rawValue }
    }

    public enum RegistryType: String, CustomStringConvertible, Codable, _SotoSendable {
        case hook = "HOOK"
        case module = "MODULE"
        case resource = "RESOURCE"
        public var description: String { return self.rawValue }
    }

    public enum Replacement: String, CustomStringConvertible, Codable, _SotoSendable {
        case `false` = "False"
        case `true` = "True"
        case conditional = "Conditional"
        public var description: String { return self.rawValue }
    }

    public enum RequiresRecreation: String, CustomStringConvertible, Codable, _SotoSendable {
        case always = "Always"
        case conditionally = "Conditionally"
        case never = "Never"
        public var description: String { return self.rawValue }
    }

    public enum ResourceAttribute: String, CustomStringConvertible, Codable, _SotoSendable {
        case creationPolicy = "CreationPolicy"
        case deletionPolicy = "DeletionPolicy"
        case metadata = "Metadata"
        case properties = "Properties"
        case tags = "Tags"
        case updatePolicy = "UpdatePolicy"
        public var description: String { return self.rawValue }
    }

    public enum ResourceSignalStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case failure = "FAILURE"
        case success = "SUCCESS"
        public var description: String { return self.rawValue }
    }

    public enum ResourceStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case createComplete = "CREATE_COMPLETE"
        case createFailed = "CREATE_FAILED"
        case createInProgress = "CREATE_IN_PROGRESS"
        case deleteComplete = "DELETE_COMPLETE"
        case deleteFailed = "DELETE_FAILED"
        case deleteInProgress = "DELETE_IN_PROGRESS"
        case deleteSkipped = "DELETE_SKIPPED"
        case importComplete = "IMPORT_COMPLETE"
        case importFailed = "IMPORT_FAILED"
        case importInProgress = "IMPORT_IN_PROGRESS"
        case importRollbackComplete = "IMPORT_ROLLBACK_COMPLETE"
        case importRollbackFailed = "IMPORT_ROLLBACK_FAILED"
        case importRollbackInProgress = "IMPORT_ROLLBACK_IN_PROGRESS"
        case rollbackComplete = "ROLLBACK_COMPLETE"
        case rollbackFailed = "ROLLBACK_FAILED"
        case rollbackInProgress = "ROLLBACK_IN_PROGRESS"
        case updateComplete = "UPDATE_COMPLETE"
        case updateFailed = "UPDATE_FAILED"
        case updateInProgress = "UPDATE_IN_PROGRESS"
        case updateRollbackComplete = "UPDATE_ROLLBACK_COMPLETE"
        case updateRollbackFailed = "UPDATE_ROLLBACK_FAILED"
        case updateRollbackInProgress = "UPDATE_ROLLBACK_IN_PROGRESS"
        public var description: String { return self.rawValue }
    }

    public enum StackDriftDetectionStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case detectionComplete = "DETECTION_COMPLETE"
        case detectionFailed = "DETECTION_FAILED"
        case detectionInProgress = "DETECTION_IN_PROGRESS"
        public var description: String { return self.rawValue }
    }

    public enum StackDriftStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case drifted = "DRIFTED"
        case inSync = "IN_SYNC"
        case notChecked = "NOT_CHECKED"
        case unknown = "UNKNOWN"
        public var description: String { return self.rawValue }
    }

    public enum StackInstanceDetailedStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case cancelled = "CANCELLED"
        case failed = "FAILED"
        case inoperable = "INOPERABLE"
        case pending = "PENDING"
        case running = "RUNNING"
        case succeeded = "SUCCEEDED"
        public var description: String { return self.rawValue }
    }

    public enum StackInstanceFilterName: String, CustomStringConvertible, Codable, _SotoSendable {
        case detailedStatus = "DETAILED_STATUS"
        case lastOperationId = "LAST_OPERATION_ID"
        public var description: String { return self.rawValue }
    }

    public enum StackInstanceStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case current = "CURRENT"
        case inoperable = "INOPERABLE"
        case outdated = "OUTDATED"
        public var description: String { return self.rawValue }
    }

    public enum StackResourceDriftStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case deleted = "DELETED"
        case inSync = "IN_SYNC"
        case modified = "MODIFIED"
        case notChecked = "NOT_CHECKED"
        public var description: String { return self.rawValue }
    }

    public enum StackSetDriftDetectionStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case completed = "COMPLETED"
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        case partialSuccess = "PARTIAL_SUCCESS"
        case stopped = "STOPPED"
        public var description: String { return self.rawValue }
    }

    public enum StackSetDriftStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case drifted = "DRIFTED"
        case inSync = "IN_SYNC"
        case notChecked = "NOT_CHECKED"
        public var description: String { return self.rawValue }
    }

    public enum StackSetOperationAction: String, CustomStringConvertible, Codable, _SotoSendable {
        case create = "CREATE"
        case delete = "DELETE"
        case detectDrift = "DETECT_DRIFT"
        case update = "UPDATE"
        public var description: String { return self.rawValue }
    }

    public enum StackSetOperationResultStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case cancelled = "CANCELLED"
        case failed = "FAILED"
        case pending = "PENDING"
        case running = "RUNNING"
        case succeeded = "SUCCEEDED"
        public var description: String { return self.rawValue }
    }

    public enum StackSetOperationStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case failed = "FAILED"
        case queued = "QUEUED"
        case running = "RUNNING"
        case stopped = "STOPPED"
        case stopping = "STOPPING"
        case succeeded = "SUCCEEDED"
        public var description: String { return self.rawValue }
    }

    public enum StackSetStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case active = "ACTIVE"
        case deleted = "DELETED"
        public var description: String { return self.rawValue }
    }

    public enum StackStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case createComplete = "CREATE_COMPLETE"
        case createFailed = "CREATE_FAILED"
        case createInProgress = "CREATE_IN_PROGRESS"
        case deleteComplete = "DELETE_COMPLETE"
        case deleteFailed = "DELETE_FAILED"
        case deleteInProgress = "DELETE_IN_PROGRESS"
        case importComplete = "IMPORT_COMPLETE"
        case importInProgress = "IMPORT_IN_PROGRESS"
        case importRollbackComplete = "IMPORT_ROLLBACK_COMPLETE"
        case importRollbackFailed = "IMPORT_ROLLBACK_FAILED"
        case importRollbackInProgress = "IMPORT_ROLLBACK_IN_PROGRESS"
        case reviewInProgress = "REVIEW_IN_PROGRESS"
        case rollbackComplete = "ROLLBACK_COMPLETE"
        case rollbackFailed = "ROLLBACK_FAILED"
        case rollbackInProgress = "ROLLBACK_IN_PROGRESS"
        case updateComplete = "UPDATE_COMPLETE"
        case updateCompleteCleanupInProgress = "UPDATE_COMPLETE_CLEANUP_IN_PROGRESS"
        case updateFailed = "UPDATE_FAILED"
        case updateInProgress = "UPDATE_IN_PROGRESS"
        case updateRollbackComplete = "UPDATE_ROLLBACK_COMPLETE"
        case updateRollbackCompleteCleanupInProgress = "UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS"
        case updateRollbackFailed = "UPDATE_ROLLBACK_FAILED"
        case updateRollbackInProgress = "UPDATE_ROLLBACK_IN_PROGRESS"
        public var description: String { return self.rawValue }
    }

    public enum TemplateStage: String, CustomStringConvertible, Codable, _SotoSendable {
        case original = "Original"
        case processed = "Processed"
        public var description: String { return self.rawValue }
    }

    public enum ThirdPartyType: String, CustomStringConvertible, Codable, _SotoSendable {
        case hook = "HOOK"
        case module = "MODULE"
        case resource = "RESOURCE"
        public var description: String { return self.rawValue }
    }

    public enum TypeTestsStatus: String, CustomStringConvertible, Codable, _SotoSendable {
        case failed = "FAILED"
        case inProgress = "IN_PROGRESS"
        case notTested = "NOT_TESTED"
        case passed = "PASSED"
        public var description: String { return self.rawValue }
    }

    public enum VersionBump: String, CustomStringConvertible, Codable, _SotoSendable {
        case major = "MAJOR"
        case minor = "MINOR"
        public var description: String { return self.rawValue }
    }

    public enum Visibility: String, CustomStringConvertible, Codable, _SotoSendable {
        case `private` = "PRIVATE"
        case `public` = "PUBLIC"
        public var description: String { return self.rawValue }
    }

    // MARK: Shapes

    public struct AccountGateResult: AWSDecodableShape {
        /// The status of the account gate function.    SUCCEEDED: The account gate function has determined that the account and Region passes any requirements for a stack set operation to occur. CloudFormation proceeds with the stack operation in that account and Region.    FAILED: The account gate function has determined that the account and Region doesn't meet the requirements for a stack set operation to occur. CloudFormation cancels the stack set operation in that account and Region, and sets the stack set operation result status for that account and Region to FAILED.    SKIPPED: CloudFormation has skipped calling the account gate function for this account and Region, for one of the following reasons:   An account gate function hasn't been specified for the account and Region. CloudFormation proceeds with the stack set operation in this account and Region.   The AWSCloudFormationStackSetExecutionRole of the stack set administration account lacks permissions to invoke the function. CloudFormation proceeds with the stack set operation in this account and Region.   Either no action is necessary, or no action is possible, on the stack. CloudFormation skips the stack set operation in this account and Region.
        public let status: AccountGateStatus?
        /// The reason for the account gate status assigned to this account and Region for the stack set operation.
        public let statusReason: String?

        public init(status: AccountGateStatus? = nil, statusReason: String? = nil) {
            self.status = status
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case status = "Status"
            case statusReason = "StatusReason"
        }
    }

    public struct AccountLimit: AWSDecodableShape {
        /// The name of the account limit. Values: ConcurrentResourcesLimit | StackLimit | StackOutputsLimit
        public let name: String?
        /// The value that's associated with the account limit name.
        public let value: Int?

        public init(name: String? = nil, value: Int? = nil) {
            self.name = name
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case value = "Value"
        }
    }

    public struct ActivateTypeInput: AWSEncodableShape {
        /// Whether to automatically update the extension in this account and region when a new minor version is published by the extension publisher. Major versions released by the publisher must be manually updated. The default is true.
        public let autoUpdate: Bool?
        /// The name of the IAM execution role to use to activate the extension.
        public let executionRoleArn: String?
        public let loggingConfig: LoggingConfig?
        /// The major version of this extension you want to activate, if multiple major versions are available. The default is the latest major version. CloudFormation uses the latest available minor version of the major version selected. You can specify MajorVersion or VersionBump, but not both.
        public let majorVersion: Int64?
        /// The Amazon Resource Name (ARN) of the public extension. Conditional: You must specify PublicTypeArn, or TypeName, Type, and PublisherId.
        public let publicTypeArn: String?
        /// The ID of the extension publisher. Conditional: You must specify PublicTypeArn, or TypeName, Type, and PublisherId.
        public let publisherId: String?
        /// The extension type. Conditional: You must specify PublicTypeArn, or TypeName, Type, and PublisherId.
        public let type: ThirdPartyType?
        /// The name of the extension. Conditional: You must specify PublicTypeArn, or TypeName, Type, and PublisherId.
        public let typeName: String?
        /// An alias to assign to the public extension, in this account and region. If you specify an alias for the extension, CloudFormation treats the alias as the extension type name within this account and region. You must use the alias to refer to the extension in your templates, API calls, and CloudFormation console. An extension alias must be unique within a given account and region. You can activate the same public resource multiple times in the same account and region, using different type name aliases.
        public let typeNameAlias: String?
        /// Manually updates a previously-activated type to a new major or minor version, if available. You can also use this parameter to update the value of AutoUpdate.    MAJOR: CloudFormation updates the extension to the newest major version, if one is available.    MINOR: CloudFormation updates the extension to the newest minor version, if one is available.
        public let versionBump: VersionBump?

        public init(autoUpdate: Bool? = nil, executionRoleArn: String? = nil, loggingConfig: LoggingConfig? = nil, majorVersion: Int64? = nil, publicTypeArn: String? = nil, publisherId: String? = nil, type: ThirdPartyType? = nil, typeName: String? = nil, typeNameAlias: String? = nil, versionBump: VersionBump? = nil) {
            self.autoUpdate = autoUpdate
            self.executionRoleArn = executionRoleArn
            self.loggingConfig = loggingConfig
            self.majorVersion = majorVersion
            self.publicTypeArn = publicTypeArn
            self.publisherId = publisherId
            self.type = type
            self.typeName = typeName
            self.typeNameAlias = typeNameAlias
            self.versionBump = versionBump
        }

        public func validate(name: String) throws {
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, max: 256)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, min: 1)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, pattern: "^arn:.+:iam::[0-9]{12}:role/.+$")
            try self.loggingConfig?.validate(name: "\(name).loggingConfig")
            try self.validate(self.majorVersion, name: "majorVersion", parent: name, max: 100_000)
            try self.validate(self.majorVersion, name: "majorVersion", parent: name, min: 1)
            try self.validate(self.publicTypeArn, name: "publicTypeArn", parent: name, max: 1024)
            try self.validate(self.publicTypeArn, name: "publicTypeArn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}::type/.+/[0-9a-zA-Z]{12,40}/.+$")
            try self.validate(self.publisherId, name: "publisherId", parent: name, max: 40)
            try self.validate(self.publisherId, name: "publisherId", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, pattern: "^[0-9a-zA-Z]{12,40}$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
            try self.validate(self.typeNameAlias, name: "typeNameAlias", parent: name, max: 204)
            try self.validate(self.typeNameAlias, name: "typeNameAlias", parent: name, min: 10)
            try self.validate(self.typeNameAlias, name: "typeNameAlias", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case autoUpdate = "AutoUpdate"
            case executionRoleArn = "ExecutionRoleArn"
            case loggingConfig = "LoggingConfig"
            case majorVersion = "MajorVersion"
            case publicTypeArn = "PublicTypeArn"
            case publisherId = "PublisherId"
            case type = "Type"
            case typeName = "TypeName"
            case typeNameAlias = "TypeNameAlias"
            case versionBump = "VersionBump"
        }
    }

    public struct ActivateTypeOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the activated extension, in this account and region.
        public let arn: String?

        public init(arn: String? = nil) {
            self.arn = arn
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
        }
    }

    public struct AutoDeployment: AWSEncodableShape & AWSDecodableShape {
        /// If set to true, StackSets automatically deploys additional stack instances to Organizations accounts that are added to a target organization or organizational unit (OU) in the specified Regions. If an account is removed from a target organization or OU, StackSets deletes stack instances from the account in the specified Regions.
        public let enabled: Bool?
        /// If set to true, stack resources are retained when an account is removed from a target organization or OU. If set to false, stack resources are deleted. Specify only if Enabled is set to True.
        public let retainStacksOnAccountRemoval: Bool?

        public init(enabled: Bool? = nil, retainStacksOnAccountRemoval: Bool? = nil) {
            self.enabled = enabled
            self.retainStacksOnAccountRemoval = retainStacksOnAccountRemoval
        }

        private enum CodingKeys: String, CodingKey {
            case enabled = "Enabled"
            case retainStacksOnAccountRemoval = "RetainStacksOnAccountRemoval"
        }
    }

    public struct BatchDescribeTypeConfigurationsError: AWSDecodableShape {
        /// The error code.
        public let errorCode: String?
        /// The error message.
        public let errorMessage: String?
        public let typeConfigurationIdentifier: TypeConfigurationIdentifier?

        public init(errorCode: String? = nil, errorMessage: String? = nil, typeConfigurationIdentifier: TypeConfigurationIdentifier? = nil) {
            self.errorCode = errorCode
            self.errorMessage = errorMessage
            self.typeConfigurationIdentifier = typeConfigurationIdentifier
        }

        private enum CodingKeys: String, CodingKey {
            case errorCode = "ErrorCode"
            case errorMessage = "ErrorMessage"
            case typeConfigurationIdentifier = "TypeConfigurationIdentifier"
        }
    }

    public struct BatchDescribeTypeConfigurationsInput: AWSEncodableShape {
        /// The list of identifiers for the desired extension configurations.
        @CustomCoding<StandardArrayCoder>
        public var typeConfigurationIdentifiers: [TypeConfigurationIdentifier]

        public init(typeConfigurationIdentifiers: [TypeConfigurationIdentifier]) {
            self.typeConfigurationIdentifiers = typeConfigurationIdentifiers
        }

        public func validate(name: String) throws {
            try self.typeConfigurationIdentifiers.forEach {
                try $0.validate(name: "\(name).typeConfigurationIdentifiers[]")
            }
            try self.validate(self.typeConfigurationIdentifiers, name: "typeConfigurationIdentifiers", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case typeConfigurationIdentifiers = "TypeConfigurationIdentifiers"
        }
    }

    public struct BatchDescribeTypeConfigurationsOutput: AWSDecodableShape {
        /// A list of information concerning any errors generated during the setting of the specified configurations.
        @OptionalCustomCoding<StandardArrayCoder>
        public var errors: [BatchDescribeTypeConfigurationsError]?
        /// A list of any of the specified extension configurations from the CloudFormation registry.
        @OptionalCustomCoding<StandardArrayCoder>
        public var typeConfigurations: [TypeConfigurationDetails]?
        /// A list of any of the specified extension configurations that CloudFormation could not process for any reason.
        @OptionalCustomCoding<StandardArrayCoder>
        public var unprocessedTypeConfigurations: [TypeConfigurationIdentifier]?

        public init(errors: [BatchDescribeTypeConfigurationsError]? = nil, typeConfigurations: [TypeConfigurationDetails]? = nil, unprocessedTypeConfigurations: [TypeConfigurationIdentifier]? = nil) {
            self.errors = errors
            self.typeConfigurations = typeConfigurations
            self.unprocessedTypeConfigurations = unprocessedTypeConfigurations
        }

        private enum CodingKeys: String, CodingKey {
            case errors = "Errors"
            case typeConfigurations = "TypeConfigurations"
            case unprocessedTypeConfigurations = "UnprocessedTypeConfigurations"
        }
    }

    public struct CancelUpdateStackInput: AWSEncodableShape {
        /// A unique identifier for this CancelUpdateStack request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to cancel an update on a stack with the same name. You might retry CancelUpdateStack requests to ensure that CloudFormation successfully received them.
        public let clientRequestToken: String?
        /// The name or the unique stack ID that's associated with the stack.
        public let stackName: String

        public init(clientRequestToken: String? = nil, stackName: String) {
            self.clientRequestToken = clientRequestToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case stackName = "StackName"
        }
    }

    public struct Change: AWSDecodableShape {
        /// Is either null, if no hooks invoke for the resource, or contains the number of hooks that will invoke for the resource.
        public let hookInvocationCount: Int?
        /// A ResourceChange structure that describes the resource and action that CloudFormation will perform.
        public let resourceChange: ResourceChange?
        /// The type of entity that CloudFormation changes. Currently, the only entity type is Resource.
        public let type: ChangeType?

        public init(hookInvocationCount: Int? = nil, resourceChange: ResourceChange? = nil, type: ChangeType? = nil) {
            self.hookInvocationCount = hookInvocationCount
            self.resourceChange = resourceChange
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case hookInvocationCount = "HookInvocationCount"
            case resourceChange = "ResourceChange"
            case type = "Type"
        }
    }

    public struct ChangeSetHook: AWSDecodableShape {
        /// Specify the hook failure mode for non-compliant resources in the followings ways.    FAIL Stops provisioning resources.    WARN Allows provisioning to continue with a warning message.
        public let failureMode: HookFailureMode?
        /// Specifies the points in provisioning logic where a hook is invoked.
        public let invocationPoint: HookInvocationPoint?
        /// Specifies details about the target that the hook will run against.
        public let targetDetails: ChangeSetHookTargetDetails?
        /// The version ID of the type configuration.
        public let typeConfigurationVersionId: String?
        /// The unique name for your hook. Specifies a three-part namespace for your hook, with a recommended pattern of Organization::Service::Hook.  The following organization namespaces are reserved and can't be used in your hook type names:    Alexa     AMZN     Amazon     ASK     AWS     Custom     Dev
        public let typeName: String?
        /// The version ID of the type specified.
        public let typeVersionId: String?

        public init(failureMode: HookFailureMode? = nil, invocationPoint: HookInvocationPoint? = nil, targetDetails: ChangeSetHookTargetDetails? = nil, typeConfigurationVersionId: String? = nil, typeName: String? = nil, typeVersionId: String? = nil) {
            self.failureMode = failureMode
            self.invocationPoint = invocationPoint
            self.targetDetails = targetDetails
            self.typeConfigurationVersionId = typeConfigurationVersionId
            self.typeName = typeName
            self.typeVersionId = typeVersionId
        }

        private enum CodingKeys: String, CodingKey {
            case failureMode = "FailureMode"
            case invocationPoint = "InvocationPoint"
            case targetDetails = "TargetDetails"
            case typeConfigurationVersionId = "TypeConfigurationVersionId"
            case typeName = "TypeName"
            case typeVersionId = "TypeVersionId"
        }
    }

    public struct ChangeSetHookResourceTargetDetails: AWSDecodableShape {
        /// The resource's logical ID, which is defined in the stack's template.
        public let logicalResourceId: String?
        /// Specifies the action of the resource.
        public let resourceAction: ChangeAction?
        /// The type of CloudFormation resource, such as AWS::S3::Bucket.
        public let resourceType: String?

        public init(logicalResourceId: String? = nil, resourceAction: ChangeAction? = nil, resourceType: String? = nil) {
            self.logicalResourceId = logicalResourceId
            self.resourceAction = resourceAction
            self.resourceType = resourceType
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case resourceAction = "ResourceAction"
            case resourceType = "ResourceType"
        }
    }

    public struct ChangeSetHookTargetDetails: AWSDecodableShape {
        /// Required if TargetType is RESOURCE.
        public let resourceTargetDetails: ChangeSetHookResourceTargetDetails?
        /// The name of the type.
        public let targetType: HookTargetType?

        public init(resourceTargetDetails: ChangeSetHookResourceTargetDetails? = nil, targetType: HookTargetType? = nil) {
            self.resourceTargetDetails = resourceTargetDetails
            self.targetType = targetType
        }

        private enum CodingKeys: String, CodingKey {
            case resourceTargetDetails = "ResourceTargetDetails"
            case targetType = "TargetType"
        }
    }

    public struct ChangeSetSummary: AWSDecodableShape {
        /// The ID of the change set.
        public let changeSetId: String?
        /// The name of the change set.
        public let changeSetName: String?
        /// The start time when the change set was created, in UTC.
        public let creationTime: Date?
        /// Descriptive information about the change set.
        public let description: String?
        /// If the change set execution status is AVAILABLE, you can execute the change set. If you can't execute the change set, the status indicates why. For example, a change set might be in an UNAVAILABLE state because CloudFormation is still creating it or in an OBSOLETE state because the stack was already updated.
        public let executionStatus: ExecutionStatus?
        /// Specifies the current setting of IncludeNestedStacks for the change set.
        public let includeNestedStacks: Bool?
        /// The parent change set ID.
        public let parentChangeSetId: String?
        /// The root change set ID.
        public let rootChangeSetId: String?
        /// The ID of the stack with which the change set is associated.
        public let stackId: String?
        /// The name of the stack with which the change set is associated.
        public let stackName: String?
        /// The state of the change set, such as CREATE_IN_PROGRESS, CREATE_COMPLETE, or FAILED.
        public let status: ChangeSetStatus?
        /// A description of the change set's status. For example, if your change set is in the FAILED state, CloudFormation shows the error message.
        public let statusReason: String?

        public init(changeSetId: String? = nil, changeSetName: String? = nil, creationTime: Date? = nil, description: String? = nil, executionStatus: ExecutionStatus? = nil, includeNestedStacks: Bool? = nil, parentChangeSetId: String? = nil, rootChangeSetId: String? = nil, stackId: String? = nil, stackName: String? = nil, status: ChangeSetStatus? = nil, statusReason: String? = nil) {
            self.changeSetId = changeSetId
            self.changeSetName = changeSetName
            self.creationTime = creationTime
            self.description = description
            self.executionStatus = executionStatus
            self.includeNestedStacks = includeNestedStacks
            self.parentChangeSetId = parentChangeSetId
            self.rootChangeSetId = rootChangeSetId
            self.stackId = stackId
            self.stackName = stackName
            self.status = status
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetId = "ChangeSetId"
            case changeSetName = "ChangeSetName"
            case creationTime = "CreationTime"
            case description = "Description"
            case executionStatus = "ExecutionStatus"
            case includeNestedStacks = "IncludeNestedStacks"
            case parentChangeSetId = "ParentChangeSetId"
            case rootChangeSetId = "RootChangeSetId"
            case stackId = "StackId"
            case stackName = "StackName"
            case status = "Status"
            case statusReason = "StatusReason"
        }
    }

    public struct ContinueUpdateRollbackInput: AWSEncodableShape {
        /// A unique identifier for this ContinueUpdateRollback request. Specify this token if you plan to retry requests so that CloudFormationknows that you're not attempting to continue the rollback to a stack with the same name. You might retry ContinueUpdateRollback requests to ensure that CloudFormation successfully received them.
        public let clientRequestToken: String?
        /// A list of the logical IDs of the resources that CloudFormation skips during the continue update rollback operation. You can specify only resources that are in the UPDATE_FAILED state because a rollback failed. You can't specify resources that are in the UPDATE_FAILED state for other reasons, for example, because an update was canceled. To check why a resource update failed, use the DescribeStackResources action, and view the resource status reason.  Specify this property to skip rolling back resources that CloudFormation can't successfully roll back. We recommend that you  troubleshoot resources before skipping them. CloudFormation sets the status of the specified resources to UPDATE_COMPLETE and continues to roll back the stack. After the rollback is complete, the state of the skipped resources will be inconsistent with the state of the resources in the stack template. Before performing another stack update, you must update the stack or resources to be consistent with each other. If you don't, subsequent stack updates might fail, and the stack will become unrecoverable.  Specify the minimum number of resources required to successfully roll back your stack. For example, a failed resource update might cause dependent resources to fail. In this case, it might not be necessary to skip the dependent resources. To skip resources that are part of nested stacks, use the following format: NestedStackName.ResourceLogicalID. If you want to specify the logical ID of a stack resource (Type: AWS::CloudFormation::Stack) in the ResourcesToSkip list, then its corresponding embedded stack must be in one of the following states: DELETE_IN_PROGRESS, DELETE_COMPLETE, or DELETE_FAILED.  Don't confuse a child stack's name with its corresponding logical ID defined in the parent stack. For an example of a continue update rollback operation with nested stacks, see Using ResourcesToSkip to recover a nested stacks hierarchy.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourcesToSkip: [String]?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFormation assumes to roll back the stack. CloudFormation uses the role's credentials to make calls on your behalf. CloudFormation always uses this role for all future operations on the stack. Provided that users have permission to operate on the stack, CloudFormation uses this role even if the users don't have permission to pass it. Ensure that the role grants least permission. If you don't specify a value, CloudFormation uses the role that was previously associated with the stack. If no role is available, CloudFormation uses a temporary session that's generated from your user credentials.
        public let roleARN: String?
        /// The name or the unique ID of the stack that you want to continue rolling back.  Don't specify the name of a nested stack (a stack that was created by using the AWS::CloudFormation::Stack resource). Instead, use this operation on the parent stack (the stack that contains the AWS::CloudFormation::Stack resource).
        public let stackName: String

        public init(clientRequestToken: String? = nil, resourcesToSkip: [String]? = nil, roleARN: String? = nil, stackName: String) {
            self.clientRequestToken = clientRequestToken
            self.resourcesToSkip = resourcesToSkip
            self.roleARN = roleARN
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.resourcesToSkip?.forEach {
                try validate($0, name: "resourcesToSkip[]", parent: name, pattern: "^[a-zA-Z0-9]+|[a-zA-Z][-a-zA-Z0-9]*\\.[a-zA-Z0-9]+$")
            }
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case resourcesToSkip = "ResourcesToSkip"
            case roleARN = "RoleARN"
            case stackName = "StackName"
        }
    }

    public struct ContinueUpdateRollbackOutput: AWSDecodableShape {
        public init() {}
    }

    public struct CreateChangeSetInput: AWSEncodableShape {
        /// In some cases, you must explicitly acknowledge that your stack template contains certain capabilities in order for CloudFormation to create the stack.    CAPABILITY_IAM and CAPABILITY_NAMED_IAM  Some stack templates might include resources that can affect permissions in your Amazon Web Services account; for example, by creating new Identity and Access Management (IAM) users. For those stacks, you must explicitly acknowledge this by specifying one of these capabilities. The following IAM resources require you to specify either the CAPABILITY_IAM or CAPABILITY_NAMED_IAM capability.   If you have IAM resources, you can specify either capability.   If you have IAM resources with custom names, you must specify CAPABILITY_NAMED_IAM.   If you don't specify either of these capabilities, CloudFormation returns an InsufficientCapabilities error.   If your stack template contains these resources, we suggest that you review all permissions associated with them and edit their permissions if necessary.     AWS::IAM::AccessKey      AWS::IAM::Group     AWS::IAM::InstanceProfile      AWS::IAM::Policy      AWS::IAM::Role      AWS::IAM::User     AWS::IAM::UserToGroupAddition    For more information, see Acknowledging IAM resources in CloudFormation templates.    CAPABILITY_AUTO_EXPAND  Some template contain macros. Macros perform custom processing on templates; this can include simple actions like find-and-replace operations, all the way to extensive transformations of entire templates. Because of this, users typically create a change set from the processed template, so that they can review the changes resulting from the macros before actually creating the stack. If your stack template contains one or more macros, and you choose to create a stack directly from the processed template, without first reviewing the resulting changes in a change set, you must acknowledge this capability. This includes the AWS::Include and AWS::Serverless transforms, which are macros hosted by CloudFormation.  This capacity doesn't apply to creating change sets, and specifying it when creating change sets has no effect. If you want to create a stack from a stack template that contains macros and nested stacks, you must create or update the stack directly from the template using the CreateStack or UpdateStack action, and specifying this capability.  For more information about macros, see Using CloudFormation macros to perform custom processing on templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// The name of the change set. The name must be unique among all change sets that are associated with the specified stack. A change set name can contain only alphanumeric, case sensitive characters, and hyphens. It must start with an alphabetical character and can't exceed 128 characters.
        public let changeSetName: String
        /// The type of change set operation. To create a change set for a new stack, specify CREATE. To create a change set for an existing stack, specify UPDATE. To create a change set for an import operation, specify IMPORT. If you create a change set for a new stack, CloudFormation creates a stack with a unique stack ID, but no template or resources. The stack will be in the  REVIEW_IN_PROGRESS state until you execute the change set. By default, CloudFormation specifies UPDATE. You can't use the UPDATE type to create a change set for a new stack or the CREATE type to create a change set for an existing stack.
        public let changeSetType: ChangeSetType?
        /// A unique identifier for this CreateChangeSet request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to create another change set with the same name. You might retry CreateChangeSet requests to ensure that CloudFormation successfully received them.
        public let clientToken: String?
        /// A description to help you identify this change set.
        public let description: String?
        /// Creates a change set for the all nested stacks specified in the template. The default behavior of this action is set to False. To include nested sets in a change set, specify True.
        public let includeNestedStacks: Bool?
        /// The Amazon Resource Names (ARNs) of Amazon Simple Notification Service (Amazon SNS) topics that CloudFormation associates with the stack. To remove all associated notification topics, specify an empty list.
        @OptionalCustomCoding<StandardArrayCoder>
        public var notificationARNs: [String]?
        /// A list of Parameter structures that specify input parameters for the change set. For more information, see the Parameter data type.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// The resources to import into your stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourcesToImport: [ResourceToImport]?
        /// The template resource types that you have permissions to work with if you execute this change set, such as AWS::EC2::Instance, AWS::EC2::*, or Custom::MyCustomInstance. If the list of resource types doesn't include a resource type that you're updating, the stack update fails. By default, CloudFormation grants permissions to all resource types. Identity and Access Management (IAM) uses this parameter for condition keys in IAM policies for CloudFormation. For more information, see Controlling access with Identity and Access Management in the CloudFormation User Guide.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceTypes: [String]?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFormation assumes when executing the change set. CloudFormation uses the role's credentials to make calls on your behalf. CloudFormation uses this role for all future operations on the stack. Provided that users have permission to operate on the stack, CloudFormation uses this role even if the users don't have permission to pass it. Ensure that the role grants least permission. If you don't specify a value, CloudFormation uses the role that was previously associated with the stack. If no role is available, CloudFormation uses a temporary session that is generated from your user credentials.
        public let roleARN: String?
        /// The rollback triggers for CloudFormation to monitor during stack creation and updating operations, and for the specified monitoring period afterwards.
        public let rollbackConfiguration: RollbackConfiguration?
        /// The name or the unique ID of the stack for which you are creating a change set. CloudFormation generates the change set by comparing this stack's information with the information that you submit, such as a modified template or different parameter input values.
        public let stackName: String
        /// Key-value pairs to associate with this stack. CloudFormation also propagates these tags to resources in the stack. You can specify a maximum of 50 tags.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// A structure that contains the body of the revised template, with a minimum length of 1 byte and a maximum length of 51,200 bytes. CloudFormation generates the change set by comparing this template with the template of the stack that you specified. Conditional: You must specify only TemplateBody or TemplateURL.
        public let templateBody: String?
        /// The location of the file that contains the revised template. The URL must point to a template (max size: 460,800 bytes) that's located in an Amazon S3 bucket or a Systems Manager document. CloudFormation generates the change set by comparing this template with the stack that you specified. Conditional: You must specify only TemplateBody or TemplateURL.
        public let templateURL: String?
        /// Whether to reuse the template that's associated with the stack to create the change set.
        public let usePreviousTemplate: Bool?

        public init(capabilities: [Capability]? = nil, changeSetName: String, changeSetType: ChangeSetType? = nil, clientToken: String? = nil, description: String? = nil, includeNestedStacks: Bool? = nil, notificationARNs: [String]? = nil, parameters: [Parameter]? = nil, resourcesToImport: [ResourceToImport]? = nil, resourceTypes: [String]? = nil, roleARN: String? = nil, rollbackConfiguration: RollbackConfiguration? = nil, stackName: String, tags: [Tag]? = nil, templateBody: String? = nil, templateURL: String? = nil, usePreviousTemplate: Bool? = nil) {
            self.capabilities = capabilities
            self.changeSetName = changeSetName
            self.changeSetType = changeSetType
            self.clientToken = clientToken
            self.description = description
            self.includeNestedStacks = includeNestedStacks
            self.notificationARNs = notificationARNs
            self.parameters = parameters
            self.resourcesToImport = resourcesToImport
            self.resourceTypes = resourceTypes
            self.roleARN = roleARN
            self.rollbackConfiguration = rollbackConfiguration
            self.stackName = stackName
            self.tags = tags
            self.templateBody = templateBody
            self.templateURL = templateURL
            self.usePreviousTemplate = usePreviousTemplate
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 128)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*$")
            try self.validate(self.clientToken, name: "clientToken", parent: name, max: 128)
            try self.validate(self.clientToken, name: "clientToken", parent: name, min: 1)
            try self.validate(self.description, name: "description", parent: name, max: 1024)
            try self.validate(self.description, name: "description", parent: name, min: 1)
            try self.validate(self.notificationARNs, name: "notificationARNs", parent: name, max: 5)
            try self.resourcesToImport?.forEach {
                try $0.validate(name: "\(name).resourcesToImport[]")
            }
            try self.validate(self.resourcesToImport, name: "resourcesToImport", parent: name, max: 200)
            try self.resourceTypes?.forEach {
                try validate($0, name: "resourceTypes[]", parent: name, max: 256)
                try validate($0, name: "resourceTypes[]", parent: name, min: 1)
            }
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
            try self.rollbackConfiguration?.validate(name: "\(name).rollbackConfiguration")
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case changeSetName = "ChangeSetName"
            case changeSetType = "ChangeSetType"
            case clientToken = "ClientToken"
            case description = "Description"
            case includeNestedStacks = "IncludeNestedStacks"
            case notificationARNs = "NotificationARNs"
            case parameters = "Parameters"
            case resourcesToImport = "ResourcesToImport"
            case resourceTypes = "ResourceTypes"
            case roleARN = "RoleARN"
            case rollbackConfiguration = "RollbackConfiguration"
            case stackName = "StackName"
            case tags = "Tags"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
            case usePreviousTemplate = "UsePreviousTemplate"
        }
    }

    public struct CreateChangeSetOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the change set.
        public let id: String?
        /// The unique ID of the stack.
        public let stackId: String?

        public init(id: String? = nil, stackId: String? = nil) {
            self.id = id
            self.stackId = stackId
        }

        private enum CodingKeys: String, CodingKey {
            case id = "Id"
            case stackId = "StackId"
        }
    }

    public struct CreateStackInput: AWSEncodableShape {
        /// In some cases, you must explicitly acknowledge that your stack template contains certain capabilities in order for CloudFormation to create the stack.    CAPABILITY_IAM and CAPABILITY_NAMED_IAM  Some stack templates might include resources that can affect permissions in your Amazon Web Services account; for example, by creating new Identity and Access Management (IAM) users. For those stacks, you must explicitly acknowledge this by specifying one of these capabilities. The following IAM resources require you to specify either the CAPABILITY_IAM or CAPABILITY_NAMED_IAM capability.   If you have IAM resources, you can specify either capability.   If you have IAM resources with custom names, you must specify CAPABILITY_NAMED_IAM.   If you don't specify either of these capabilities, CloudFormation returns an InsufficientCapabilities error.   If your stack template contains these resources, we recommend that you review all permissions associated with them and edit their permissions if necessary.     AWS::IAM::AccessKey      AWS::IAM::Group     AWS::IAM::InstanceProfile      AWS::IAM::Policy      AWS::IAM::Role      AWS::IAM::User     AWS::IAM::UserToGroupAddition    For more information, see Acknowledging IAM Resources in CloudFormation Templates.    CAPABILITY_AUTO_EXPAND  Some template contain macros. Macros perform custom processing on templates; this can include simple actions like find-and-replace operations, all the way to extensive transformations of entire templates. Because of this, users typically create a change set from the processed template, so that they can review the changes resulting from the macros before actually creating the stack. If your stack template contains one or more macros, and you choose to create a stack directly from the processed template, without first reviewing the resulting changes in a change set, you must acknowledge this capability. This includes the AWS::Include and AWS::Serverless transforms, which are macros hosted by CloudFormation. If you want to create a stack from a stack template that contains macros and nested stacks, you must create the stack directly from the template using this capability.  You should only create stacks directly from a stack template that contains macros if you know what processing the macro performs. Each macro relies on an underlying Lambda service function for processing stack templates. Be aware that the Lambda function owner can update the function operation without CloudFormation being notified.  For more information, see Using CloudFormation macros to perform custom processing on templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// A unique identifier for this CreateStack request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to create a stack with the same name. You might retry CreateStack requests to ensure that CloudFormation successfully received them. All events initiated by a given stack operation are assigned the same client request token, which you can use to track operations. For example, if you execute a CreateStack operation with the token token1, then all the StackEvents generated by that operation will have ClientRequestToken set as token1. In the console, stack operations display the client request token on the Events tab. Stack operations that are initiated from the console use the token format Console-StackOperation-ID, which helps you easily identify the stack operation . For example, if you create a stack using the console, each stack event would be assigned the same token in the following format: Console-CreateStack-7f59c3cf-00d2-40c7-b2ff-e75db0987002.
        public let clientRequestToken: String?
        /// Set to true to disable rollback of the stack if stack creation failed. You can specify either DisableRollback or OnFailure, but not both. Default: false
        public let disableRollback: Bool?
        /// Whether to enable termination protection on the specified stack. If a user attempts to delete a stack with termination protection enabled, the operation fails and the stack remains unchanged. For more information, see Protecting a Stack From Being Deleted in the CloudFormation User Guide. Termination protection is deactivated on stacks by default. For nested stacks, termination protection is set on the root stack and can't be changed directly on the nested stack.
        public let enableTerminationProtection: Bool?
        /// The Amazon Simple Notification Service (Amazon SNS) topic ARNs to publish stack related events. You can find your Amazon SNS topic ARNs using the Amazon SNS console or your Command Line Interface (CLI).
        @OptionalCustomCoding<StandardArrayCoder>
        public var notificationARNs: [String]?
        /// Determines what action will be taken if stack creation fails. This must be one of: DO_NOTHING, ROLLBACK, or DELETE. You can specify either OnFailure or DisableRollback, but not both. Default: ROLLBACK
        public let onFailure: OnFailure?
        /// A list of Parameter structures that specify input parameters for the stack. For more information, see the Parameter data type.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// The template resource types that you have permissions to work with for this create stack action, such as AWS::EC2::Instance, AWS::EC2::*, or Custom::MyCustomInstance. Use the following syntax to describe template resource types: AWS::* (for all Amazon Web Services resources), Custom::* (for all custom resources), Custom::logical_ID (for a specific custom resource), AWS::service_name::* (for all resources of a particular Amazon Web Services service), and AWS::service_name::resource_logical_ID (for a specific Amazon Web Services resource). If the list of resource types doesn't include a resource that you're creating, the stack creation fails. By default, CloudFormation grants permissions to all resource types. Identity and Access Management (IAM) uses this parameter for CloudFormation-specific condition keys in IAM policies. For more information, see Controlling Access with Identity and Access Management.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceTypes: [String]?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFormation assumes to create the stack. CloudFormation uses the role's credentials to make calls on your behalf. CloudFormation always uses this role for all future operations on the stack. Provided that users have permission to operate on the stack, CloudFormation uses this role even if the users don't have permission to pass it. Ensure that the role grants least privilege. If you don't specify a value, CloudFormation uses the role that was previously associated with the stack. If no role is available, CloudFormation uses a temporary session that's generated from your user credentials.
        public let roleARN: String?
        /// The rollback triggers for CloudFormation to monitor during stack creation and updating operations, and for the specified monitoring period afterwards.
        public let rollbackConfiguration: RollbackConfiguration?
        /// The name that's associated with the stack. The name must be unique in the Region in which you are creating the stack.  A stack name can contain only alphanumeric characters (case sensitive) and hyphens. It must start with an alphabetical character and can't be longer than 128 characters.
        public let stackName: String
        /// Structure containing the stack policy body. For more information, go to  Prevent Updates to Stack Resources in the CloudFormation User Guide. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both.
        public let stackPolicyBody: String?
        /// Location of a file containing the stack policy. The URL must point to a policy (maximum size: 16 KB) located in an S3 bucket in the same Region as the stack. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both.
        public let stackPolicyURL: String?
        /// Key-value pairs to associate with this stack. CloudFormation also propagates these tags to the resources created in the stack. A maximum number of 50 tags can be specified.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information, go to Template anatomy in the CloudFormation User Guide. Conditional: You must specify either the TemplateBody or the TemplateURL parameter, but not both.
        public let templateBody: String?
        /// Location of file containing the template body. The URL must point to a template (max size: 460,800 bytes) that's located in an Amazon S3 bucket or a Systems Manager document. For more information, go to the Template anatomy in the CloudFormation User Guide. Conditional: You must specify either the TemplateBody or the TemplateURL parameter, but not both.
        public let templateURL: String?
        /// The amount of time that can pass before the stack status becomes CREATE_FAILED; if DisableRollback is not set or is set to false, the stack will be rolled back.
        public let timeoutInMinutes: Int?

        public init(capabilities: [Capability]? = nil, clientRequestToken: String? = nil, disableRollback: Bool? = nil, enableTerminationProtection: Bool? = nil, notificationARNs: [String]? = nil, onFailure: OnFailure? = nil, parameters: [Parameter]? = nil, resourceTypes: [String]? = nil, roleARN: String? = nil, rollbackConfiguration: RollbackConfiguration? = nil, stackName: String, stackPolicyBody: String? = nil, stackPolicyURL: String? = nil, tags: [Tag]? = nil, templateBody: String? = nil, templateURL: String? = nil, timeoutInMinutes: Int? = nil) {
            self.capabilities = capabilities
            self.clientRequestToken = clientRequestToken
            self.disableRollback = disableRollback
            self.enableTerminationProtection = enableTerminationProtection
            self.notificationARNs = notificationARNs
            self.onFailure = onFailure
            self.parameters = parameters
            self.resourceTypes = resourceTypes
            self.roleARN = roleARN
            self.rollbackConfiguration = rollbackConfiguration
            self.stackName = stackName
            self.stackPolicyBody = stackPolicyBody
            self.stackPolicyURL = stackPolicyURL
            self.tags = tags
            self.templateBody = templateBody
            self.templateURL = templateURL
            self.timeoutInMinutes = timeoutInMinutes
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.notificationARNs, name: "notificationARNs", parent: name, max: 5)
            try self.resourceTypes?.forEach {
                try validate($0, name: "resourceTypes[]", parent: name, max: 256)
                try validate($0, name: "resourceTypes[]", parent: name, min: 1)
            }
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
            try self.rollbackConfiguration?.validate(name: "\(name).rollbackConfiguration")
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, max: 16384)
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, min: 1)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, max: 1350)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, min: 1)
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
            try self.validate(self.timeoutInMinutes, name: "timeoutInMinutes", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case clientRequestToken = "ClientRequestToken"
            case disableRollback = "DisableRollback"
            case enableTerminationProtection = "EnableTerminationProtection"
            case notificationARNs = "NotificationARNs"
            case onFailure = "OnFailure"
            case parameters = "Parameters"
            case resourceTypes = "ResourceTypes"
            case roleARN = "RoleARN"
            case rollbackConfiguration = "RollbackConfiguration"
            case stackName = "StackName"
            case stackPolicyBody = "StackPolicyBody"
            case stackPolicyURL = "StackPolicyURL"
            case tags = "Tags"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
            case timeoutInMinutes = "TimeoutInMinutes"
        }
    }

    public struct CreateStackInstancesInput: AWSEncodableShape {
        /// [Self-managed permissions] The names of one or more Amazon Web Services accounts that you want to create stack instances in the specified Region(s) for. You can specify Accounts or DeploymentTargets, but not both.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accounts: [String]?
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// [Service-managed permissions] The Organizations accounts for which to create stack instances in the specified Amazon Web Services Regions. You can specify Accounts or DeploymentTargets, but not both.
        public let deploymentTargets: DeploymentTargets?
        /// The unique identifier for this stack set operation. The operation ID also functions as an idempotency token, to ensure that CloudFormation performs the stack set operation only once, even if you retry the request multiple times. You might retry stack set operation requests to ensure that CloudFormation successfully received them. If you don't specify an operation ID, the SDK generates one automatically. Repeating this stack set operation with a new operation ID retries all stack instances whose status is OUTDATED.
        public let operationId: String?
        /// Preferences for how CloudFormation performs this stack set operation.
        public let operationPreferences: StackSetOperationPreferences?
        /// A list of stack set parameters whose values you want to override in the selected stack instances. Any overridden parameter values will be applied to all stack instances in the specified accounts and Amazon Web Services Regions. When specifying parameters and their values, be aware of how CloudFormation sets parameter values during stack instance operations:   To override the current value for a parameter, include the parameter and specify its value.   To leave an overridden parameter set to its present value, include the parameter and specify UsePreviousValue as true. (You can't specify both a value and set UsePreviousValue to true.)   To set an overridden parameter back to the value specified in the stack set, specify a parameter list but don't include the parameter in the list.   To leave all parameters set to their present values, don't specify this property at all.   During stack set updates, any parameter values overridden for a stack instance aren't updated, but retain their overridden value. You can only override the parameter values that are specified in the stack set; to add or delete a parameter itself, use UpdateStackSet to update the stack set template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameterOverrides: [Parameter]?
        /// The names of one or more Amazon Web Services Regions where you want to create stack instances using the specified Amazon Web Services accounts.
        @CustomCoding<StandardArrayCoder>
        public var regions: [String]
        /// The name or unique ID of the stack set that you want to create stack instances from.
        public let stackSetName: String

        public init(accounts: [String]? = nil, callAs: CallAs? = nil, deploymentTargets: DeploymentTargets? = nil, operationId: String? = CreateStackInstancesInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, parameterOverrides: [Parameter]? = nil, regions: [String], stackSetName: String) {
            self.accounts = accounts
            self.callAs = callAs
            self.deploymentTargets = deploymentTargets
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.parameterOverrides = parameterOverrides
            self.regions = regions
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.accounts?.forEach {
                try validate($0, name: "accounts[]", parent: name, pattern: "^[0-9]{12}$")
            }
            try self.deploymentTargets?.validate(name: "\(name).deploymentTargets")
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.regions.forEach {
                try validate($0, name: "regions[]", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case accounts = "Accounts"
            case callAs = "CallAs"
            case deploymentTargets = "DeploymentTargets"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case parameterOverrides = "ParameterOverrides"
            case regions = "Regions"
            case stackSetName = "StackSetName"
        }
    }

    public struct CreateStackInstancesOutput: AWSDecodableShape {
        /// The unique identifier for this stack set operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct CreateStackOutput: AWSDecodableShape {
        /// Unique identifier of the stack.
        public let stackId: String?

        public init(stackId: String? = nil) {
            self.stackId = stackId
        }

        private enum CodingKeys: String, CodingKey {
            case stackId = "StackId"
        }
    }

    public struct CreateStackSetInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the IAM role to use to create this stack set. Specify an IAM role only if you are using customized administrator roles to control which users or groups can manage specific stack sets within the same administrator account. For more information, see Prerequisites: Granting Permissions for Stack Set Operations in the CloudFormation User Guide.
        public let administrationRoleARN: String?
        /// Describes whether StackSets automatically deploys to Organizations accounts that are added to the target organization or organizational unit (OU). Specify only if PermissionModel is SERVICE_MANAGED.
        public let autoDeployment: AutoDeployment?
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   To create a stack set with service-managed permissions while signed in to the management account, specify SELF.   To create a stack set with service-managed permissions while signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated admin in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.   Stack sets with service-managed permissions are created in the management account, including stack sets that are created by delegated administrators.
        public let callAs: CallAs?
        /// In some cases, you must explicitly acknowledge that your stack set template contains certain capabilities in order for CloudFormation to create the stack set and related stack instances.    CAPABILITY_IAM and CAPABILITY_NAMED_IAM  Some stack templates might include resources that can affect permissions in your Amazon Web Services account; for example, by creating new Identity and Access Management (IAM) users. For those stack sets, you must explicitly acknowledge this by specifying one of these capabilities. The following IAM resources require you to specify either the CAPABILITY_IAM or CAPABILITY_NAMED_IAM capability.   If you have IAM resources, you can specify either capability.   If you have IAM resources with custom names, you must specify CAPABILITY_NAMED_IAM.   If you don't specify either of these capabilities, CloudFormation returns an InsufficientCapabilities error.   If your stack template contains these resources, we recommend that you review all permissions associated with them and edit their permissions if necessary.     AWS::IAM::AccessKey      AWS::IAM::Group     AWS::IAM::InstanceProfile      AWS::IAM::Policy      AWS::IAM::Role      AWS::IAM::User     AWS::IAM::UserToGroupAddition    For more information, see Acknowledging IAM Resources in CloudFormation Templates.    CAPABILITY_AUTO_EXPAND  Some templates reference macros. If your stack set template references one or more macros, you must create the stack set directly from the processed template, without first reviewing the resulting changes in a change set. To create the stack set directly, you must acknowledge this capability. For more information, see Using CloudFormation Macros to Perform Custom Processing on Templates.  Stack sets with service-managed permissions don't currently support the use of macros in templates. (This includes the AWS::Include and AWS::Serverless transforms, which are macros hosted by CloudFormation.) Even if you specify this capability for a stack set with service-managed permissions, if you reference a macro in your template the stack set operation will fail.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// A unique identifier for this CreateStackSet request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to create another stack set with the same name. You might retry CreateStackSet requests to ensure that CloudFormation successfully received them. If you don't specify an operation ID, the SDK generates one automatically.
        public let clientRequestToken: String?
        /// A description of the stack set. You can use the description to identify the stack set's purpose or other important information.
        public let description: String?
        /// The name of the IAM execution role to use to create the stack set. If you do not specify an execution role, CloudFormation uses the AWSCloudFormationStackSetExecutionRole role for the stack set operation. Specify an IAM role only if you are using customized execution roles to control which stack resources users and groups can include in their stack sets.
        public let executionRoleName: String?
        /// Describes whether StackSets performs non-conflicting operations concurrently and queues conflicting operations.
        public let managedExecution: ManagedExecution?
        /// The input parameters for the stack set template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// Describes how the IAM roles required for stack set operations are created. By default, SELF-MANAGED is specified.   With self-managed permissions, you must create the administrator and execution roles required to deploy to target accounts. For more information, see Grant Self-Managed Stack Set Permissions.   With service-managed permissions, StackSets automatically creates the IAM roles required to deploy to accounts managed by Organizations. For more information, see Grant Service-Managed Stack Set Permissions.
        public let permissionModel: PermissionModels?
        /// The stack ID you are importing into a new stack set. Specify the Amazon Resource Name (ARN) of the stack.
        public let stackId: String?
        /// The name to associate with the stack set. The name must be unique in the Region where you create your stack set.  A stack name can contain only alphanumeric characters (case-sensitive) and hyphens. It must start with an alphabetic character and can't be longer than 128 characters.
        public let stackSetName: String
        /// The key-value pairs to associate with this stack set and the stacks created from it. CloudFormation also propagates these tags to supported resources that are created in the stacks. A maximum number of 50 tags can be specified. If you specify tags as part of a CreateStackSet action, CloudFormation checks to see if you have the required IAM permission to tag resources. If you don't, the entire CreateStackSet action fails with an access denied error, and the stack set is not created.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// The structure that contains the template body, with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information, see Template Anatomy in the CloudFormation User Guide. Conditional: You must specify either the TemplateBody or the TemplateURL parameter, but not both.
        public let templateBody: String?
        /// The location of the file that contains the template body. The URL must point to a template (maximum size: 460,800 bytes) that's located in an Amazon S3 bucket or a Systems Manager document. For more information, see Template Anatomy in the CloudFormation User Guide. Conditional: You must specify either the TemplateBody or the TemplateURL parameter, but not both.
        public let templateURL: String?

        public init(administrationRoleARN: String? = nil, autoDeployment: AutoDeployment? = nil, callAs: CallAs? = nil, capabilities: [Capability]? = nil, clientRequestToken: String? = CreateStackSetInput.idempotencyToken(), description: String? = nil, executionRoleName: String? = nil, managedExecution: ManagedExecution? = nil, parameters: [Parameter]? = nil, permissionModel: PermissionModels? = nil, stackId: String? = nil, stackSetName: String, tags: [Tag]? = nil, templateBody: String? = nil, templateURL: String? = nil) {
            self.administrationRoleARN = administrationRoleARN
            self.autoDeployment = autoDeployment
            self.callAs = callAs
            self.capabilities = capabilities
            self.clientRequestToken = clientRequestToken
            self.description = description
            self.executionRoleName = executionRoleName
            self.managedExecution = managedExecution
            self.parameters = parameters
            self.permissionModel = permissionModel
            self.stackId = stackId
            self.stackSetName = stackSetName
            self.tags = tags
            self.templateBody = templateBody
            self.templateURL = templateURL
        }

        public func validate(name: String) throws {
            try self.validate(self.administrationRoleARN, name: "administrationRoleARN", parent: name, max: 2048)
            try self.validate(self.administrationRoleARN, name: "administrationRoleARN", parent: name, min: 20)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.description, name: "description", parent: name, max: 1024)
            try self.validate(self.description, name: "description", parent: name, min: 1)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, max: 64)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, min: 1)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, pattern: "^[a-zA-Z_0-9+=,.@-]+$")
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case administrationRoleARN = "AdministrationRoleARN"
            case autoDeployment = "AutoDeployment"
            case callAs = "CallAs"
            case capabilities = "Capabilities"
            case clientRequestToken = "ClientRequestToken"
            case description = "Description"
            case executionRoleName = "ExecutionRoleName"
            case managedExecution = "ManagedExecution"
            case parameters = "Parameters"
            case permissionModel = "PermissionModel"
            case stackId = "StackId"
            case stackSetName = "StackSetName"
            case tags = "Tags"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
        }
    }

    public struct CreateStackSetOutput: AWSDecodableShape {
        /// The ID of the stack set that you're creating.
        public let stackSetId: String?

        public init(stackSetId: String? = nil) {
            self.stackSetId = stackSetId
        }

        private enum CodingKeys: String, CodingKey {
            case stackSetId = "StackSetId"
        }
    }

    public struct DeactivateTypeInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) for the extension, in this account and region. Conditional: You must specify either Arn, or TypeName and Type.
        public let arn: String?
        /// The extension type. Conditional: You must specify either Arn, or TypeName and Type.
        public let type: ThirdPartyType?
        /// The type name of the extension, in this account and region. If you specified a type name alias when enabling the extension, use the type name alias. Conditional: You must specify either Arn, or TypeName and Type.
        public let typeName: String?

        public init(arn: String? = nil, type: ThirdPartyType? = nil, typeName: String? = nil) {
            self.arn = arn
            self.type = type
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:[0-9]{12}:type/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case type = "Type"
            case typeName = "TypeName"
        }
    }

    public struct DeactivateTypeOutput: AWSDecodableShape {
        public init() {}
    }

    public struct DeleteChangeSetInput: AWSEncodableShape {
        /// The name or Amazon Resource Name (ARN) of the change set that you want to delete.
        public let changeSetName: String
        /// If you specified the name of a change set to delete, specify the stack name or Amazon Resource Name (ARN) that's associated with it.
        public let stackName: String?

        public init(changeSetName: String, stackName: String? = nil) {
            self.changeSetName = changeSetName
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 1600)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*|arn:[-a-zA-Z0-9:/]*$")
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetName = "ChangeSetName"
            case stackName = "StackName"
        }
    }

    public struct DeleteChangeSetOutput: AWSDecodableShape {
        public init() {}
    }

    public struct DeleteStackInput: AWSEncodableShape {
        /// A unique identifier for this DeleteStack request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to delete a stack with the same name. You might retry DeleteStack requests to ensure that CloudFormation successfully received them. All events initiated by a given stack operation are assigned the same client request token, which you can use to track operations. For example, if you execute a CreateStack operation with the token token1, then all the StackEvents generated by that operation will have ClientRequestToken set as token1. In the console, stack operations display the client request token on the Events tab. Stack operations that are initiated from the console use the token format Console-StackOperation-ID, which helps you easily identify the stack operation . For example, if you create a stack using the console, each stack event would be assigned the same token in the following format: Console-CreateStack-7f59c3cf-00d2-40c7-b2ff-e75db0987002.
        public let clientRequestToken: String?
        /// For stacks in the DELETE_FAILED state, a list of resource logical IDs that are associated with the resources you want to retain. During deletion, CloudFormation deletes the stack but doesn't delete the retained resources. Retaining resources is useful when you can't delete a resource, such as a non-empty S3 bucket, but you want to delete the stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var retainResources: [String]?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFormation assumes to delete the stack. CloudFormation uses the role's credentials to make calls on your behalf. If you don't specify a value, CloudFormation uses the role that was previously associated with the stack. If no role is available, CloudFormation uses a temporary session that's generated from your user credentials.
        public let roleARN: String?
        /// The name or the unique stack ID that's associated with the stack.
        public let stackName: String

        public init(clientRequestToken: String? = nil, retainResources: [String]? = nil, roleARN: String? = nil, stackName: String) {
            self.clientRequestToken = clientRequestToken
            self.retainResources = retainResources
            self.roleARN = roleARN
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case retainResources = "RetainResources"
            case roleARN = "RoleARN"
            case stackName = "StackName"
        }
    }

    public struct DeleteStackInstancesInput: AWSEncodableShape {
        /// [Self-managed permissions] The names of the Amazon Web Services accounts that you want to delete stack instances for. You can specify Accounts or DeploymentTargets, but not both.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accounts: [String]?
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// [Service-managed permissions] The Organizations accounts from which to delete stack instances. You can specify Accounts or DeploymentTargets, but not both.
        public let deploymentTargets: DeploymentTargets?
        /// The unique identifier for this stack set operation. If you don't specify an operation ID, the SDK generates one automatically. The operation ID also functions as an idempotency token, to ensure that CloudFormation performs the stack set operation only once, even if you retry the request multiple times. You can retry stack set operation requests to ensure that CloudFormation successfully received them. Repeating this stack set operation with a new operation ID retries all stack instances whose status is OUTDATED.
        public let operationId: String?
        /// Preferences for how CloudFormation performs this stack set operation.
        public let operationPreferences: StackSetOperationPreferences?
        /// The Amazon Web Services Regions where you want to delete stack set instances.
        @CustomCoding<StandardArrayCoder>
        public var regions: [String]
        /// Removes the stack instances from the specified stack set, but doesn't delete the stacks. You can't reassociate a retained stack or add an existing, saved stack to a new stack set. For more information, see Stack set operation options.
        public let retainStacks: Bool
        /// The name or unique ID of the stack set that you want to delete stack instances for.
        public let stackSetName: String

        public init(accounts: [String]? = nil, callAs: CallAs? = nil, deploymentTargets: DeploymentTargets? = nil, operationId: String? = DeleteStackInstancesInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, regions: [String], retainStacks: Bool = false, stackSetName: String) {
            self.accounts = accounts
            self.callAs = callAs
            self.deploymentTargets = deploymentTargets
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.regions = regions
            self.retainStacks = retainStacks
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.accounts?.forEach {
                try validate($0, name: "accounts[]", parent: name, pattern: "^[0-9]{12}$")
            }
            try self.deploymentTargets?.validate(name: "\(name).deploymentTargets")
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.regions.forEach {
                try validate($0, name: "regions[]", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case accounts = "Accounts"
            case callAs = "CallAs"
            case deploymentTargets = "DeploymentTargets"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case regions = "Regions"
            case retainStacks = "RetainStacks"
            case stackSetName = "StackSetName"
        }
    }

    public struct DeleteStackInstancesOutput: AWSDecodableShape {
        /// The unique identifier for this stack set operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct DeleteStackSetInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The name or unique ID of the stack set that you're deleting. You can obtain this value by running ListStackSets.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, stackSetName: String) {
            self.callAs = callAs
            self.stackSetName = stackSetName
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case stackSetName = "StackSetName"
        }
    }

    public struct DeleteStackSetOutput: AWSDecodableShape {
        public init() {}
    }

    public struct DeploymentTargets: AWSEncodableShape & AWSDecodableShape {
        /// Limit deployment targets to individual accounts or include additional accounts with provided OUs. The following is a list of possible values for the AccountFilterType operation.    INTERSECTION: StackSets deploys to the accounts specified in Accounts parameter.     DIFFERENCE: StackSets excludes the accounts specified in Accounts parameter. This enables user to avoid certain accounts within an OU such as suspended accounts.    UNION: StackSets includes additional accounts deployment targets.  This is the default value if AccountFilterType is not provided. This enables user to update an entire OU and individual accounts from a different OU in one request, which used to be two separate requests.    NONE: Deploys to all the accounts in specified organizational units (OU).
        public let accountFilterType: AccountFilterType?
        /// The names of one or more Amazon Web Services accounts for which you want to deploy stack set updates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accounts: [String]?
        /// Returns the value of the AccountsUrl property.
        public let accountsUrl: String?
        /// The organization root ID or organizational unit (OU) IDs to which StackSets deploys.
        @OptionalCustomCoding<StandardArrayCoder>
        public var organizationalUnitIds: [String]?

        public init(accountFilterType: AccountFilterType? = nil, accounts: [String]? = nil, accountsUrl: String? = nil, organizationalUnitIds: [String]? = nil) {
            self.accountFilterType = accountFilterType
            self.accounts = accounts
            self.accountsUrl = accountsUrl
            self.organizationalUnitIds = organizationalUnitIds
        }

        public func validate(name: String) throws {
            try self.accounts?.forEach {
                try validate($0, name: "accounts[]", parent: name, pattern: "^[0-9]{12}$")
            }
            try self.validate(self.accountsUrl, name: "accountsUrl", parent: name, max: 5120)
            try self.validate(self.accountsUrl, name: "accountsUrl", parent: name, min: 1)
            try self.validate(self.accountsUrl, name: "accountsUrl", parent: name, pattern: "^(s3://|http(s?)://).+$")
            try self.organizationalUnitIds?.forEach {
                try validate($0, name: "organizationalUnitIds[]", parent: name, pattern: "^(ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}|r-[a-z0-9]{4,32})$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case accountFilterType = "AccountFilterType"
            case accounts = "Accounts"
            case accountsUrl = "AccountsUrl"
            case organizationalUnitIds = "OrganizationalUnitIds"
        }
    }

    public struct DeregisterTypeInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let arn: String?
        /// The kind of extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let type: RegistryType?
        /// The name of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeName: String?
        /// The ID of a specific version of the extension. The version ID is the value at the end of the Amazon Resource Name (ARN) assigned to the extension version when it is registered.
        public let versionId: String?

        public init(arn: String? = nil, type: RegistryType? = nil, typeName: String? = nil, versionId: String? = nil) {
            self.arn = arn
            self.type = type
            self.typeName = typeName
            self.versionId = versionId
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:[0-9]{12}:type/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
            try self.validate(self.versionId, name: "versionId", parent: name, max: 128)
            try self.validate(self.versionId, name: "versionId", parent: name, min: 1)
            try self.validate(self.versionId, name: "versionId", parent: name, pattern: "^[A-Za-z0-9-]+$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case type = "Type"
            case typeName = "TypeName"
            case versionId = "VersionId"
        }
    }

    public struct DeregisterTypeOutput: AWSDecodableShape {
        public init() {}
    }

    public struct DescribeAccountLimitsInput: AWSEncodableShape {
        /// A string that identifies the next page of limits that you want to retrieve.
        public let nextToken: String?

        public init(nextToken: String? = nil) {
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
        }
    }

    public struct DescribeAccountLimitsOutput: AWSDecodableShape {
        /// An account limit structure that contain a list of CloudFormation account limits and their values.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accountLimits: [AccountLimit]?
        /// If the output exceeds 1 MB in size, a string that identifies the next page of limits. If no additional page exists, this value is null.
        public let nextToken: String?

        public init(accountLimits: [AccountLimit]? = nil, nextToken: String? = nil) {
            self.accountLimits = accountLimits
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case accountLimits = "AccountLimits"
            case nextToken = "NextToken"
        }
    }

    public struct DescribeChangeSetHooksInput: AWSEncodableShape {
        /// The name or Amazon Resource Name (ARN) of the change set that you want to describe.
        public let changeSetName: String
        /// If specified, lists only the hooks related to the specified LogicalResourceId.
        public let logicalResourceId: String?
        /// A string, provided by the DescribeChangeSetHooks response output, that identifies the next page of information that you want to retrieve.
        public let nextToken: String?
        /// If you specified the name of a change set, specify the stack name or stack ID (ARN) of the change set you want to describe.
        public let stackName: String?

        public init(changeSetName: String, logicalResourceId: String? = nil, nextToken: String? = nil, stackName: String? = nil) {
            self.changeSetName = changeSetName
            self.logicalResourceId = logicalResourceId
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 1600)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*|arn:[-a-zA-Z0-9:/]*$")
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetName = "ChangeSetName"
            case logicalResourceId = "LogicalResourceId"
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct DescribeChangeSetHooksOutput: AWSDecodableShape {
        /// The change set identifier (stack ID).
        public let changeSetId: String?
        /// The change set name.
        public let changeSetName: String?
        /// List of hook objects.
        @OptionalCustomCoding<StandardArrayCoder>
        public var hooks: [ChangeSetHook]?
        /// Pagination token, null or empty if no more results.
        public let nextToken: String?
        /// The stack identifier (stack ID).
        public let stackId: String?
        /// The stack name.
        public let stackName: String?
        /// Provides the status of the change set hook.
        public let status: ChangeSetHooksStatus?

        public init(changeSetId: String? = nil, changeSetName: String? = nil, hooks: [ChangeSetHook]? = nil, nextToken: String? = nil, stackId: String? = nil, stackName: String? = nil, status: ChangeSetHooksStatus? = nil) {
            self.changeSetId = changeSetId
            self.changeSetName = changeSetName
            self.hooks = hooks
            self.nextToken = nextToken
            self.stackId = stackId
            self.stackName = stackName
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetId = "ChangeSetId"
            case changeSetName = "ChangeSetName"
            case hooks = "Hooks"
            case nextToken = "NextToken"
            case stackId = "StackId"
            case stackName = "StackName"
            case status = "Status"
        }
    }

    public struct DescribeChangeSetInput: AWSEncodableShape {
        /// The name or Amazon Resource Name (ARN) of the change set that you want to describe.
        public let changeSetName: String
        /// A string (provided by the DescribeChangeSet response output) that identifies the next page of information that you want to retrieve.
        public let nextToken: String?
        /// If you specified the name of a change set, specify the stack name or ID (ARN) of the change set you want to describe.
        public let stackName: String?

        public init(changeSetName: String, nextToken: String? = nil, stackName: String? = nil) {
            self.changeSetName = changeSetName
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 1600)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*|arn:[-a-zA-Z0-9:/]*$")
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetName = "ChangeSetName"
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct DescribeChangeSetOutput: AWSDecodableShape {
        /// If you execute the change set, the list of capabilities that were explicitly acknowledged when the change set was created.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// A list of Change structures that describes the resources CloudFormation changes if you execute the change set.
        @OptionalCustomCoding<StandardArrayCoder>
        public var changes: [Change]?
        /// The Amazon Resource Name (ARN) of the change set.
        public let changeSetId: String?
        /// The name of the change set.
        public let changeSetName: String?
        /// The start time when the change set was created, in UTC.
        public let creationTime: Date?
        /// Information about the change set.
        public let description: String?
        /// If the change set execution status is AVAILABLE, you can execute the change set. If you can't execute the change set, the status indicates why. For example, a change set might be in an UNAVAILABLE state because CloudFormation is still creating it or in an OBSOLETE state because the stack was already updated.
        public let executionStatus: ExecutionStatus?
        /// Verifies if IncludeNestedStacks is set to True.
        public let includeNestedStacks: Bool?
        /// If the output exceeds 1 MB, a string that identifies the next page of changes. If there is no additional page, this value is null.
        public let nextToken: String?
        /// The ARNs of the Amazon Simple Notification Service (Amazon SNS) topics that will be associated with the stack if you execute the change set.
        @OptionalCustomCoding<StandardArrayCoder>
        public var notificationARNs: [String]?
        /// A list of Parameter structures that describes the input parameters and their values used to create the change set. For more information, see the Parameter data type.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// Specifies the change set ID of the parent change set in the current nested change set hierarchy.
        public let parentChangeSetId: String?
        /// The rollback triggers for CloudFormation to monitor during stack creation and updating operations, and for the specified monitoring period afterwards.
        public let rollbackConfiguration: RollbackConfiguration?
        /// Specifies the change set ID of the root change set in the current nested change set hierarchy.
        public let rootChangeSetId: String?
        /// The Amazon Resource Name (ARN) of the stack that's associated with the change set.
        public let stackId: String?
        /// The name of the stack that's associated with the change set.
        public let stackName: String?
        /// The current status of the change set, such as CREATE_IN_PROGRESS, CREATE_COMPLETE, or FAILED.
        public let status: ChangeSetStatus?
        /// A description of the change set's status. For example, if your attempt to create a change set failed, CloudFormation shows the error message.
        public let statusReason: String?
        /// If you execute the change set, the tags that will be associated with the stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?

        public init(capabilities: [Capability]? = nil, changes: [Change]? = nil, changeSetId: String? = nil, changeSetName: String? = nil, creationTime: Date? = nil, description: String? = nil, executionStatus: ExecutionStatus? = nil, includeNestedStacks: Bool? = nil, nextToken: String? = nil, notificationARNs: [String]? = nil, parameters: [Parameter]? = nil, parentChangeSetId: String? = nil, rollbackConfiguration: RollbackConfiguration? = nil, rootChangeSetId: String? = nil, stackId: String? = nil, stackName: String? = nil, status: ChangeSetStatus? = nil, statusReason: String? = nil, tags: [Tag]? = nil) {
            self.capabilities = capabilities
            self.changes = changes
            self.changeSetId = changeSetId
            self.changeSetName = changeSetName
            self.creationTime = creationTime
            self.description = description
            self.executionStatus = executionStatus
            self.includeNestedStacks = includeNestedStacks
            self.nextToken = nextToken
            self.notificationARNs = notificationARNs
            self.parameters = parameters
            self.parentChangeSetId = parentChangeSetId
            self.rollbackConfiguration = rollbackConfiguration
            self.rootChangeSetId = rootChangeSetId
            self.stackId = stackId
            self.stackName = stackName
            self.status = status
            self.statusReason = statusReason
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case changes = "Changes"
            case changeSetId = "ChangeSetId"
            case changeSetName = "ChangeSetName"
            case creationTime = "CreationTime"
            case description = "Description"
            case executionStatus = "ExecutionStatus"
            case includeNestedStacks = "IncludeNestedStacks"
            case nextToken = "NextToken"
            case notificationARNs = "NotificationARNs"
            case parameters = "Parameters"
            case parentChangeSetId = "ParentChangeSetId"
            case rollbackConfiguration = "RollbackConfiguration"
            case rootChangeSetId = "RootChangeSetId"
            case stackId = "StackId"
            case stackName = "StackName"
            case status = "Status"
            case statusReason = "StatusReason"
            case tags = "Tags"
        }
    }

    public struct DescribePublisherInput: AWSEncodableShape {
        /// The ID of the extension publisher. If you don't supply a PublisherId, and you have registered as an extension publisher, DescribePublisher returns information about your own publisher account.
        public let publisherId: String?

        public init(publisherId: String? = nil) {
            self.publisherId = publisherId
        }

        public func validate(name: String) throws {
            try self.validate(self.publisherId, name: "publisherId", parent: name, max: 40)
            try self.validate(self.publisherId, name: "publisherId", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, pattern: "^[0-9a-zA-Z]{12,40}$")
        }

        private enum CodingKeys: String, CodingKey {
            case publisherId = "PublisherId"
        }
    }

    public struct DescribePublisherOutput: AWSDecodableShape {
        /// The type of account used as the identity provider when registering this publisher with CloudFormation.
        public let identityProvider: IdentityProvider?
        /// The ID of the extension publisher.
        public let publisherId: String?
        /// The URL to the publisher's profile with the identity provider.
        public let publisherProfile: String?
        /// Whether the publisher is verified. Currently, all registered publishers are verified.
        public let publisherStatus: PublisherStatus?

        public init(identityProvider: IdentityProvider? = nil, publisherId: String? = nil, publisherProfile: String? = nil, publisherStatus: PublisherStatus? = nil) {
            self.identityProvider = identityProvider
            self.publisherId = publisherId
            self.publisherProfile = publisherProfile
            self.publisherStatus = publisherStatus
        }

        private enum CodingKeys: String, CodingKey {
            case identityProvider = "IdentityProvider"
            case publisherId = "PublisherId"
            case publisherProfile = "PublisherProfile"
            case publisherStatus = "PublisherStatus"
        }
    }

    public struct DescribeStackDriftDetectionStatusInput: AWSEncodableShape {
        /// The ID of the drift detection results of this operation. CloudFormation generates new results, with a new drift detection ID, each time this operation is run. However, the number of drift results CloudFormation retains for any given stack, and for how long, may vary.
        public let stackDriftDetectionId: String

        public init(stackDriftDetectionId: String) {
            self.stackDriftDetectionId = stackDriftDetectionId
        }

        public func validate(name: String) throws {
            try self.validate(self.stackDriftDetectionId, name: "stackDriftDetectionId", parent: name, max: 36)
            try self.validate(self.stackDriftDetectionId, name: "stackDriftDetectionId", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case stackDriftDetectionId = "StackDriftDetectionId"
        }
    }

    public struct DescribeStackDriftDetectionStatusOutput: AWSDecodableShape {
        /// The status of the stack drift detection operation.    DETECTION_COMPLETE: The stack drift detection operation has successfully completed for all resources in the stack that support drift detection. (Resources that don't currently support stack detection remain unchecked.) If you specified logical resource IDs for CloudFormation to use as a filter for the stack drift detection operation, only the resources with those logical IDs are checked for drift.    DETECTION_FAILED: The stack drift detection operation has failed for at least one resource in the stack. Results will be available for resources on which CloudFormation successfully completed drift detection.    DETECTION_IN_PROGRESS: The stack drift detection operation is currently in progress.
        public let detectionStatus: StackDriftDetectionStatus
        /// The reason the stack drift detection operation has its current status.
        public let detectionStatusReason: String?
        /// Total number of stack resources that have drifted. This is NULL until the drift detection operation reaches a status of DETECTION_COMPLETE. This value will be 0 for stacks whose drift status is IN_SYNC.
        public let driftedStackResourceCount: Int?
        /// The ID of the drift detection results of this operation. CloudFormation generates new results, with a new drift detection ID, each time this operation is run. However, the number of reports CloudFormation retains for any given stack, and for how long, may vary.
        public let stackDriftDetectionId: String
        /// Status of the stack's actual configuration compared to its expected configuration.    DRIFTED: The stack differs from its expected template configuration. A stack is considered to have drifted if one or more of its resources have drifted.    NOT_CHECKED: CloudFormation hasn't checked if the stack differs from its expected template configuration.    IN_SYNC: The stack's actual configuration matches its expected template configuration.    UNKNOWN: This value is reserved for future use.
        public let stackDriftStatus: StackDriftStatus?
        /// The ID of the stack.
        public let stackId: String
        /// Time at which the stack drift detection operation was initiated.
        public let timestamp: Date

        public init(detectionStatus: StackDriftDetectionStatus, detectionStatusReason: String? = nil, driftedStackResourceCount: Int? = nil, stackDriftDetectionId: String, stackDriftStatus: StackDriftStatus? = nil, stackId: String, timestamp: Date) {
            self.detectionStatus = detectionStatus
            self.detectionStatusReason = detectionStatusReason
            self.driftedStackResourceCount = driftedStackResourceCount
            self.stackDriftDetectionId = stackDriftDetectionId
            self.stackDriftStatus = stackDriftStatus
            self.stackId = stackId
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case detectionStatus = "DetectionStatus"
            case detectionStatusReason = "DetectionStatusReason"
            case driftedStackResourceCount = "DriftedStackResourceCount"
            case stackDriftDetectionId = "StackDriftDetectionId"
            case stackDriftStatus = "StackDriftStatus"
            case stackId = "StackId"
            case timestamp = "Timestamp"
        }
    }

    public struct DescribeStackEventsInput: AWSEncodableShape {
        /// A string that identifies the next page of events that you want to retrieve.
        public let nextToken: String?
        /// The name or the unique stack ID that's associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value.
        public let stackName: String?

        public init(nextToken: String? = nil, stackName: String? = nil) {
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct DescribeStackEventsOutput: AWSDecodableShape {
        /// If the output exceeds 1 MB in size, a string that identifies the next page of events. If no additional page exists, this value is null.
        public let nextToken: String?
        /// A list of StackEvents structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackEvents: [StackEvent]?

        public init(nextToken: String? = nil, stackEvents: [StackEvent]? = nil) {
            self.nextToken = nextToken
            self.stackEvents = stackEvents
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackEvents = "StackEvents"
        }
    }

    public struct DescribeStackInstanceInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The ID of an Amazon Web Services account that's associated with this stack instance.
        public let stackInstanceAccount: String
        /// The name of a Region that's associated with this stack instance.
        public let stackInstanceRegion: String
        /// The name or the unique stack ID of the stack set that you want to get stack instance information for.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, stackInstanceAccount: String, stackInstanceRegion: String, stackSetName: String) {
            self.callAs = callAs
            self.stackInstanceAccount = stackInstanceAccount
            self.stackInstanceRegion = stackInstanceRegion
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.stackInstanceAccount, name: "stackInstanceAccount", parent: name, pattern: "^[0-9]{12}$")
            try self.validate(self.stackInstanceRegion, name: "stackInstanceRegion", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case stackInstanceAccount = "StackInstanceAccount"
            case stackInstanceRegion = "StackInstanceRegion"
            case stackSetName = "StackSetName"
        }
    }

    public struct DescribeStackInstanceOutput: AWSDecodableShape {
        /// The stack instance that matches the specified request parameters.
        public let stackInstance: StackInstance?

        public init(stackInstance: StackInstance? = nil) {
            self.stackInstance = stackInstance
        }

        private enum CodingKeys: String, CodingKey {
            case stackInstance = "StackInstance"
        }
    }

    public struct DescribeStackResourceDriftsInput: AWSEncodableShape {
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// A string that identifies the next page of stack resource drift results.
        public let nextToken: String?
        /// The name of the stack for which you want drift information.
        public let stackName: String
        /// The resource drift status values to use as filters for the resource drift results returned.    DELETED: The resource differs from its expected template configuration in that the resource has been deleted.    MODIFIED: One or more resource properties differ from their expected template values.    IN_SYNC: The resource's actual configuration matches its expected template configuration.    NOT_CHECKED: CloudFormation doesn't currently return this value.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackResourceDriftStatusFilters: [StackResourceDriftStatus]?

        public init(maxResults: Int? = nil, nextToken: String? = nil, stackName: String, stackResourceDriftStatusFilters: [StackResourceDriftStatus]? = nil) {
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.stackName = stackName
            self.stackResourceDriftStatusFilters = stackResourceDriftStatusFilters
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
            try self.validate(self.stackResourceDriftStatusFilters, name: "stackResourceDriftStatusFilters", parent: name, max: 4)
            try self.validate(self.stackResourceDriftStatusFilters, name: "stackResourceDriftStatusFilters", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case stackName = "StackName"
            case stackResourceDriftStatusFilters = "StackResourceDriftStatusFilters"
        }
    }

    public struct DescribeStackResourceDriftsOutput: AWSDecodableShape {
        /// If the request doesn't return all the remaining results, NextToken is set to a token. To retrieve the next set of results, call DescribeStackResourceDrifts again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// Drift information for the resources that have been checked for drift in the specified stack. This includes actual and expected configuration values for resources where CloudFormation detects drift. For a given stack, there will be one StackResourceDrift for each stack resource that has been checked for drift. Resources that haven't yet been checked for drift aren't included. Resources that do not currently support drift detection aren't checked, and so not included. For a list of resources that support drift detection, see Resources that Support Drift Detection.
        @CustomCoding<StandardArrayCoder>
        public var stackResourceDrifts: [StackResourceDrift]

        public init(nextToken: String? = nil, stackResourceDrifts: [StackResourceDrift]) {
            self.nextToken = nextToken
            self.stackResourceDrifts = stackResourceDrifts
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackResourceDrifts = "StackResourceDrifts"
        }
    }

    public struct DescribeStackResourceInput: AWSEncodableShape {
        /// The logical name of the resource as specified in the template. Default: There is no default value.
        public let logicalResourceId: String
        /// The name or the unique stack ID that's associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value.
        public let stackName: String

        public init(logicalResourceId: String, stackName: String) {
            self.logicalResourceId = logicalResourceId
            self.stackName = stackName
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case stackName = "StackName"
        }
    }

    public struct DescribeStackResourceOutput: AWSDecodableShape {
        /// A StackResourceDetail structure containing the description of the specified resource in the specified stack.
        public let stackResourceDetail: StackResourceDetail?

        public init(stackResourceDetail: StackResourceDetail? = nil) {
            self.stackResourceDetail = stackResourceDetail
        }

        private enum CodingKeys: String, CodingKey {
            case stackResourceDetail = "StackResourceDetail"
        }
    }

    public struct DescribeStackResourcesInput: AWSEncodableShape {
        /// The logical name of the resource as specified in the template. Default: There is no default value.
        public let logicalResourceId: String?
        /// The name or unique identifier that corresponds to a physical instance ID of a resource supported by CloudFormation. For example, for an Amazon Elastic Compute Cloud (EC2) instance, PhysicalResourceId corresponds to the InstanceId. You can pass the EC2 InstanceId to DescribeStackResources to find which stack the instance belongs to and what other resources are part of the stack. Required: Conditional. If you don't specify PhysicalResourceId, you must specify StackName. Default: There is no default value.
        public let physicalResourceId: String?
        /// The name or the unique stack ID that is associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value. Required: Conditional. If you don't specify StackName, you must specify PhysicalResourceId.
        public let stackName: String?

        public init(logicalResourceId: String? = nil, physicalResourceId: String? = nil, stackName: String? = nil) {
            self.logicalResourceId = logicalResourceId
            self.physicalResourceId = physicalResourceId
            self.stackName = stackName
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case physicalResourceId = "PhysicalResourceId"
            case stackName = "StackName"
        }
    }

    public struct DescribeStackResourcesOutput: AWSDecodableShape {
        /// A list of StackResource structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackResources: [StackResource]?

        public init(stackResources: [StackResource]? = nil) {
            self.stackResources = stackResources
        }

        private enum CodingKeys: String, CodingKey {
            case stackResources = "StackResources"
        }
    }

    public struct DescribeStackSetInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The name or unique ID of the stack set whose description you want.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, stackSetName: String) {
            self.callAs = callAs
            self.stackSetName = stackSetName
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case stackSetName = "StackSetName"
        }
    }

    public struct DescribeStackSetOperationInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The unique ID of the stack set operation.
        public let operationId: String
        /// The name or the unique stack ID of the stack set for the stack operation.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, operationId: String, stackSetName: String) {
            self.callAs = callAs
            self.operationId = operationId
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case operationId = "OperationId"
            case stackSetName = "StackSetName"
        }
    }

    public struct DescribeStackSetOperationOutput: AWSDecodableShape {
        /// The specified stack set operation.
        public let stackSetOperation: StackSetOperation?

        public init(stackSetOperation: StackSetOperation? = nil) {
            self.stackSetOperation = stackSetOperation
        }

        private enum CodingKeys: String, CodingKey {
            case stackSetOperation = "StackSetOperation"
        }
    }

    public struct DescribeStackSetOutput: AWSDecodableShape {
        /// The specified stack set.
        public let stackSet: StackSet?

        public init(stackSet: StackSet? = nil) {
            self.stackSet = stackSet
        }

        private enum CodingKeys: String, CodingKey {
            case stackSet = "StackSet"
        }
    }

    public struct DescribeStacksInput: AWSEncodableShape {
        /// A string that identifies the next page of stacks that you want to retrieve.
        public let nextToken: String?
        /// The name or the unique stack ID that's associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value.
        public let stackName: String?

        public init(nextToken: String? = nil, stackName: String? = nil) {
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct DescribeStacksOutput: AWSDecodableShape {
        /// If the output exceeds 1 MB in size, a string that identifies the next page of stacks. If no additional page exists, this value is null.
        public let nextToken: String?
        /// A list of stack structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stacks: [Stack]?

        public init(nextToken: String? = nil, stacks: [Stack]? = nil) {
            self.nextToken = nextToken
            self.stacks = stacks
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stacks = "Stacks"
        }
    }

    public struct DescribeTypeInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let arn: String?
        /// The version number of a public third-party extension.
        public let publicVersionNumber: String?
        /// The publisher ID of the extension publisher. Extensions provided by Amazon Web Services are not assigned a publisher ID.
        public let publisherId: String?
        /// The kind of extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let type: RegistryType?
        /// The name of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeName: String?
        /// The ID of a specific version of the extension. The version ID is the value at the end of the Amazon Resource Name (ARN) assigned to the extension version when it is registered. If you specify a VersionId, DescribeType returns information about that specific extension version. Otherwise, it returns information about the default extension version.
        public let versionId: String?

        public init(arn: String? = nil, publicVersionNumber: String? = nil, publisherId: String? = nil, type: RegistryType? = nil, typeName: String? = nil, versionId: String? = nil) {
            self.arn = arn
            self.publicVersionNumber = publicVersionNumber
            self.publisherId = publisherId
            self.type = type
            self.typeName = typeName
            self.versionId = versionId
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.publicVersionNumber, name: "publicVersionNumber", parent: name, min: 5)
            try self.validate(self.publicVersionNumber, name: "publicVersionNumber", parent: name, pattern: "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(.*)$")
            try self.validate(self.publisherId, name: "publisherId", parent: name, max: 40)
            try self.validate(self.publisherId, name: "publisherId", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, pattern: "^[0-9a-zA-Z]{12,40}$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
            try self.validate(self.versionId, name: "versionId", parent: name, max: 128)
            try self.validate(self.versionId, name: "versionId", parent: name, min: 1)
            try self.validate(self.versionId, name: "versionId", parent: name, pattern: "^[A-Za-z0-9-]+$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case publicVersionNumber = "PublicVersionNumber"
            case publisherId = "PublisherId"
            case type = "Type"
            case typeName = "TypeName"
            case versionId = "VersionId"
        }
    }

    public struct DescribeTypeOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the extension.
        public let arn: String?
        /// Whether CloudFormation automatically updates the extension in this account and region when a new minor version is published by the extension publisher. Major versions released by the publisher must be manually updated. For more information, see Activating public extensions for use in your account in the CloudFormation User Guide.
        public let autoUpdate: Bool?
        /// A JSON string that represent the current configuration data for the extension in this account and region. To set the configuration data for an extension, use SetTypeConfiguration. For more information, see Configuring extensions at the account level in the CloudFormation User Guide.
        public let configurationSchema: String?
        /// The ID of the default version of the extension. The default version is used when the extension version isn't specified. This applies only to private extensions you have registered in your account. For public extensions, both those provided by Amazon Web Services and published by third parties, CloudFormation returns null. For more information, see RegisterType. To set the default version of an extension, use  SetTypeDefaultVersion .
        public let defaultVersionId: String?
        /// The deprecation status of the extension version. Valid values include:    LIVE: The extension is activated or registered and can be used in CloudFormation operations, dependent on its provisioning behavior and visibility scope.    DEPRECATED: The extension has been deactivated or deregistered and can no longer be used in CloudFormation operations.   For public third-party extensions, CloudFormation returns null.
        public let deprecatedStatus: DeprecatedStatus?
        /// The description of the extension.
        public let description: String?
        /// The URL of a page providing detailed documentation for this extension.
        public let documentationUrl: String?
        /// The Amazon Resource Name (ARN) of the IAM execution role used to register the extension. This applies only to private extensions you have registered in your account. For more information, see RegisterType. If the registered extension calls any Amazon Web Services APIs, you must create an  IAM execution role that includes the necessary permissions to call those Amazon Web Services APIs, and provision that execution role in your account. CloudFormation then assumes that execution role to provide your extension with the appropriate credentials.
        public let executionRoleArn: String?
        /// Whether the extension is activated in the account and region. This only applies to public third-party extensions. For all other extensions, CloudFormation returns null.
        public let isActivated: Bool?
        /// Whether the specified extension version is set as the default version. This applies only to private extensions you have registered in your account, and extensions published by Amazon Web Services. For public third-party extensions, whether they are activated in your account, CloudFormation returns null.
        public let isDefaultVersion: Bool?
        /// When the specified extension version was registered. This applies only to:   Private extensions you have registered in your account. For more information, see RegisterType.   Public extensions you have activated in your account with auto-update specified. For more information, see ActivateType.
        public let lastUpdated: Date?
        /// The latest version of a public extension that is available for use. This only applies if you specify a public extension, and you don't specify a version. For all other requests, CloudFormation returns null.
        public let latestPublicVersion: String?
        /// Contains logging configuration information for private extensions. This applies only to private extensions you have registered in your account. For public extensions, both those provided by Amazon Web Services and published by third parties, CloudFormation returns null. For more information, see RegisterType.
        public let loggingConfig: LoggingConfig?
        /// For public extensions that have been activated for this account and region, the Amazon Resource Name (ARN) of the public extension.
        public let originalTypeArn: String?
        /// For public extensions that have been activated for this account and region, the type name of the public extension. If you specified a TypeNameAlias when enabling the extension in this account and region, CloudFormation treats that alias as the extension's type name within the account and region, not the type name of the public extension. For more information, see Specifying aliases to refer to extensions in the CloudFormation User Guide.
        public let originalTypeName: String?
        /// For resource type extensions, the provisioning behavior of the resource type. CloudFormation determines the provisioning type during registration, based on the types of handlers in the schema handler package submitted. Valid values include:    FULLY_MUTABLE: The resource type includes an update handler to process updates to the type during stack update operations.    IMMUTABLE: The resource type doesn't include an update handler, so the type can't be updated and must instead be replaced during stack update operations.    NON_PROVISIONABLE: The resource type doesn't include all the following handlers, and therefore can't actually be provisioned.   create   read   delete
        public let provisioningType: ProvisioningType?
        /// The version number of a public third-party extension. This applies only if you specify a public extension you have activated in your account, or specify a public extension without specifying a version. For all other extensions, CloudFormation returns null.
        public let publicVersionNumber: String?
        /// The publisher ID of the extension publisher. This applies only to public third-party extensions. For private registered extensions, and extensions provided by Amazon Web Services, CloudFormation returns null.
        public let publisherId: String?
        /// For extensions that are modules, the public third-party extensions that must be activated in your account in order for the module itself to be activated.
        @OptionalCustomCoding<StandardArrayCoder>
        public var requiredActivatedTypes: [RequiredActivatedType]?
        /// The schema that defines the extension. For more information about extension schemas, see Resource Provider Schema in the CloudFormation CLI User Guide.
        public let schema: String?
        /// The URL of the source code for the extension.
        public let sourceUrl: String?
        /// When the specified private extension version was registered or activated in your account.
        public let timeCreated: Date?
        /// The kind of extension.
        public let type: RegistryType?
        /// The name of the extension. If the extension is a public third-party type you have activated with a type name alias, CloudFormation returns the type name alias. For more information, see ActivateType.
        public let typeName: String?
        /// The contract test status of the registered extension version. To return the extension test status of a specific extension version, you must specify VersionId. This applies only to registered private extension versions. CloudFormation doesn't return this information for public extensions, whether they are activated in your account.    PASSED: The extension has passed all its contract tests. An extension must have a test status of PASSED before it can be published. For more information, see Publishing extensions to make them available for public use in the CloudFormation Command Line Interface User Guide.    FAILED: The extension has failed one or more contract tests.    IN_PROGRESS: Contract tests are currently being performed on the extension.    NOT_TESTED: Contract tests haven't been performed on the extension.
        public let typeTestsStatus: TypeTestsStatus?
        /// The description of the test status. To return the extension test status of a specific extension version, you must specify VersionId. This applies only to registered private extension versions. CloudFormation doesn't return this information for public extensions, whether they are activated in your account.
        public let typeTestsStatusDescription: String?
        /// The scope at which the extension is visible and usable in CloudFormation operations. Valid values include:    PRIVATE: The extension is only visible and usable within the account in which it is registered. CloudFormation marks any extensions you register as PRIVATE.    PUBLIC: The extension is publicly visible and usable within any Amazon Web Services account.
        public let visibility: Visibility?

        public init(arn: String? = nil, autoUpdate: Bool? = nil, configurationSchema: String? = nil, defaultVersionId: String? = nil, deprecatedStatus: DeprecatedStatus? = nil, description: String? = nil, documentationUrl: String? = nil, executionRoleArn: String? = nil, isActivated: Bool? = nil, isDefaultVersion: Bool? = nil, lastUpdated: Date? = nil, latestPublicVersion: String? = nil, loggingConfig: LoggingConfig? = nil, originalTypeArn: String? = nil, originalTypeName: String? = nil, provisioningType: ProvisioningType? = nil, publicVersionNumber: String? = nil, publisherId: String? = nil, requiredActivatedTypes: [RequiredActivatedType]? = nil, schema: String? = nil, sourceUrl: String? = nil, timeCreated: Date? = nil, type: RegistryType? = nil, typeName: String? = nil, typeTestsStatus: TypeTestsStatus? = nil, typeTestsStatusDescription: String? = nil, visibility: Visibility? = nil) {
            self.arn = arn
            self.autoUpdate = autoUpdate
            self.configurationSchema = configurationSchema
            self.defaultVersionId = defaultVersionId
            self.deprecatedStatus = deprecatedStatus
            self.description = description
            self.documentationUrl = documentationUrl
            self.executionRoleArn = executionRoleArn
            self.isActivated = isActivated
            self.isDefaultVersion = isDefaultVersion
            self.lastUpdated = lastUpdated
            self.latestPublicVersion = latestPublicVersion
            self.loggingConfig = loggingConfig
            self.originalTypeArn = originalTypeArn
            self.originalTypeName = originalTypeName
            self.provisioningType = provisioningType
            self.publicVersionNumber = publicVersionNumber
            self.publisherId = publisherId
            self.requiredActivatedTypes = requiredActivatedTypes
            self.schema = schema
            self.sourceUrl = sourceUrl
            self.timeCreated = timeCreated
            self.type = type
            self.typeName = typeName
            self.typeTestsStatus = typeTestsStatus
            self.typeTestsStatusDescription = typeTestsStatusDescription
            self.visibility = visibility
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case autoUpdate = "AutoUpdate"
            case configurationSchema = "ConfigurationSchema"
            case defaultVersionId = "DefaultVersionId"
            case deprecatedStatus = "DeprecatedStatus"
            case description = "Description"
            case documentationUrl = "DocumentationUrl"
            case executionRoleArn = "ExecutionRoleArn"
            case isActivated = "IsActivated"
            case isDefaultVersion = "IsDefaultVersion"
            case lastUpdated = "LastUpdated"
            case latestPublicVersion = "LatestPublicVersion"
            case loggingConfig = "LoggingConfig"
            case originalTypeArn = "OriginalTypeArn"
            case originalTypeName = "OriginalTypeName"
            case provisioningType = "ProvisioningType"
            case publicVersionNumber = "PublicVersionNumber"
            case publisherId = "PublisherId"
            case requiredActivatedTypes = "RequiredActivatedTypes"
            case schema = "Schema"
            case sourceUrl = "SourceUrl"
            case timeCreated = "TimeCreated"
            case type = "Type"
            case typeName = "TypeName"
            case typeTestsStatus = "TypeTestsStatus"
            case typeTestsStatusDescription = "TypeTestsStatusDescription"
            case visibility = "Visibility"
        }
    }

    public struct DescribeTypeRegistrationInput: AWSEncodableShape {
        /// The identifier for this registration request. This registration token is generated by CloudFormation when you initiate a registration request using  RegisterType .
        public let registrationToken: String

        public init(registrationToken: String) {
            self.registrationToken = registrationToken
        }

        public func validate(name: String) throws {
            try self.validate(self.registrationToken, name: "registrationToken", parent: name, max: 128)
            try self.validate(self.registrationToken, name: "registrationToken", parent: name, min: 1)
            try self.validate(self.registrationToken, name: "registrationToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case registrationToken = "RegistrationToken"
        }
    }

    public struct DescribeTypeRegistrationOutput: AWSDecodableShape {
        /// The description of the extension registration request.
        public let description: String?
        /// The current status of the extension registration request.
        public let progressStatus: RegistrationStatus?
        /// The Amazon Resource Name (ARN) of the extension being registered. For registration requests with a ProgressStatus of other than COMPLETE, this will be null.
        public let typeArn: String?
        /// The Amazon Resource Name (ARN) of this specific version of the extension being registered. For registration requests with a ProgressStatus of other than COMPLETE, this will be null.
        public let typeVersionArn: String?

        public init(description: String? = nil, progressStatus: RegistrationStatus? = nil, typeArn: String? = nil, typeVersionArn: String? = nil) {
            self.description = description
            self.progressStatus = progressStatus
            self.typeArn = typeArn
            self.typeVersionArn = typeVersionArn
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case progressStatus = "ProgressStatus"
            case typeArn = "TypeArn"
            case typeVersionArn = "TypeVersionArn"
        }
    }

    public struct DetectStackDriftInput: AWSEncodableShape {
        /// The logical names of any resources you want to use as filters.
        @OptionalCustomCoding<StandardArrayCoder>
        public var logicalResourceIds: [String]?
        /// The name of the stack for which you want to detect drift.
        public let stackName: String

        public init(logicalResourceIds: [String]? = nil, stackName: String) {
            self.logicalResourceIds = logicalResourceIds
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.logicalResourceIds, name: "logicalResourceIds", parent: name, max: 200)
            try self.validate(self.logicalResourceIds, name: "logicalResourceIds", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceIds = "LogicalResourceIds"
            case stackName = "StackName"
        }
    }

    public struct DetectStackDriftOutput: AWSDecodableShape {
        /// The ID of the drift detection results of this operation. CloudFormation generates new results, with a new drift detection ID, each time this operation is run. However, the number of drift results CloudFormation retains for any given stack, and for how long, may vary.
        public let stackDriftDetectionId: String

        public init(stackDriftDetectionId: String) {
            self.stackDriftDetectionId = stackDriftDetectionId
        }

        private enum CodingKeys: String, CodingKey {
            case stackDriftDetectionId = "StackDriftDetectionId"
        }
    }

    public struct DetectStackResourceDriftInput: AWSEncodableShape {
        /// The logical name of the resource for which to return drift information.
        public let logicalResourceId: String
        /// The name of the stack to which the resource belongs.
        public let stackName: String

        public init(logicalResourceId: String, stackName: String) {
            self.logicalResourceId = logicalResourceId
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case stackName = "StackName"
        }
    }

    public struct DetectStackResourceDriftOutput: AWSDecodableShape {
        /// Information about whether the resource's actual configuration has drifted from its expected template configuration, including actual and expected property values and any differences detected.
        public let stackResourceDrift: StackResourceDrift

        public init(stackResourceDrift: StackResourceDrift) {
            self.stackResourceDrift = stackResourceDrift
        }

        private enum CodingKeys: String, CodingKey {
            case stackResourceDrift = "StackResourceDrift"
        }
    }

    public struct DetectStackSetDriftInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        ///  The ID of the stack set operation.
        public let operationId: String?
        public let operationPreferences: StackSetOperationPreferences?
        /// The name of the stack set on which to perform the drift detection operation.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, operationId: String? = DetectStackSetDriftInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, stackSetName: String) {
            self.callAs = callAs
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.validate(self.stackSetName, name: "stackSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*(?::[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12})?$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case stackSetName = "StackSetName"
        }
    }

    public struct DetectStackSetDriftOutput: AWSDecodableShape {
        /// The ID of the drift detection stack set operation. You can use this operation ID with  DescribeStackSetOperation to monitor the progress of the drift detection operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct EstimateTemplateCostInput: AWSEncodableShape {
        /// A list of Parameter structures that specify input parameters.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. (For more information, go to Template Anatomy in the CloudFormation User Guide.) Conditional: You must pass TemplateBody or TemplateURL. If both are passed, only TemplateBody is used.
        public let templateBody: String?
        /// Location of file containing the template body. The URL must point to a template that's located in an Amazon S3 bucket or a Systems Manager document. For more information, go to Template Anatomy in the CloudFormation User Guide. Conditional: You must pass TemplateURL or TemplateBody. If both are passed, only TemplateBody is used.
        public let templateURL: String?

        public init(parameters: [Parameter]? = nil, templateBody: String? = nil, templateURL: String? = nil) {
            self.parameters = parameters
            self.templateBody = templateBody
            self.templateURL = templateURL
        }

        public func validate(name: String) throws {
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case parameters = "Parameters"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
        }
    }

    public struct EstimateTemplateCostOutput: AWSDecodableShape {
        /// An Amazon Web Services Simple Monthly Calculator URL with a query string that describes the resources required to run the template.
        public let url: String?

        public init(url: String? = nil) {
            self.url = url
        }

        private enum CodingKeys: String, CodingKey {
            case url = "Url"
        }
    }

    public struct ExecuteChangeSetInput: AWSEncodableShape {
        /// The name or Amazon Resource Name (ARN) of the change set that you want use to update the specified stack.
        public let changeSetName: String
        /// A unique identifier for this ExecuteChangeSet request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to execute a change set to update a stack with the same name. You might retry ExecuteChangeSet requests to ensure that CloudFormation successfully received them.
        public let clientRequestToken: String?
        /// Preserves the state of previously provisioned resources when an operation fails. Default: True
        public let disableRollback: Bool?
        /// If you specified the name of a change set, specify the stack name or Amazon Resource Name (ARN) that's associated with the change set you want to execute.
        public let stackName: String?

        public init(changeSetName: String, clientRequestToken: String? = nil, disableRollback: Bool? = nil, stackName: String? = nil) {
            self.changeSetName = changeSetName
            self.clientRequestToken = clientRequestToken
            self.disableRollback = disableRollback
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 1600)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*|arn:[-a-zA-Z0-9:/]*$")
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetName = "ChangeSetName"
            case clientRequestToken = "ClientRequestToken"
            case disableRollback = "DisableRollback"
            case stackName = "StackName"
        }
    }

    public struct ExecuteChangeSetOutput: AWSDecodableShape {
        public init() {}
    }

    public struct Export: AWSDecodableShape {
        /// The stack that contains the exported output name and value.
        public let exportingStackId: String?
        /// The name of exported output value. Use this name and the Fn::ImportValue function to import the associated value into other stacks. The name is defined in the Export field in the associated stack's Outputs section.
        public let name: String?
        /// The value of the exported output, such as a resource physical ID. This value is defined in the Export field in the associated stack's Outputs section.
        public let value: String?

        public init(exportingStackId: String? = nil, name: String? = nil, value: String? = nil) {
            self.exportingStackId = exportingStackId
            self.name = name
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case exportingStackId = "ExportingStackId"
            case name = "Name"
            case value = "Value"
        }
    }

    public struct GetStackPolicyInput: AWSEncodableShape {
        /// The name or unique stack ID that's associated with the stack whose policy you want to get.
        public let stackName: String

        public init(stackName: String) {
            self.stackName = stackName
        }

        private enum CodingKeys: String, CodingKey {
            case stackName = "StackName"
        }
    }

    public struct GetStackPolicyOutput: AWSDecodableShape {
        /// Structure containing the stack policy body. (For more information, go to  Prevent Updates to Stack Resources in the CloudFormation User Guide.)
        public let stackPolicyBody: String?

        public init(stackPolicyBody: String? = nil) {
            self.stackPolicyBody = stackPolicyBody
        }

        private enum CodingKeys: String, CodingKey {
            case stackPolicyBody = "StackPolicyBody"
        }
    }

    public struct GetTemplateInput: AWSEncodableShape {
        /// The name or Amazon Resource Name (ARN) of a change set for which CloudFormation returns the associated template. If you specify a name, you must also specify the StackName.
        public let changeSetName: String?
        /// The name or the unique stack ID that's associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value.
        public let stackName: String?
        /// For templates that include transforms, the stage of the template that CloudFormation returns. To get the user-submitted template, specify Original. To get the template after CloudFormation has processed all transforms, specify Processed. If the template doesn't include transforms, Original and Processed return the same template. By default, CloudFormation specifies Processed.
        public let templateStage: TemplateStage?

        public init(changeSetName: String? = nil, stackName: String? = nil, templateStage: TemplateStage? = nil) {
            self.changeSetName = changeSetName
            self.stackName = stackName
            self.templateStage = templateStage
        }

        public func validate(name: String) throws {
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, max: 1600)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, min: 1)
            try self.validate(self.changeSetName, name: "changeSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*|arn:[-a-zA-Z0-9:/]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case changeSetName = "ChangeSetName"
            case stackName = "StackName"
            case templateStage = "TemplateStage"
        }
    }

    public struct GetTemplateOutput: AWSDecodableShape {
        /// The stage of the template that you can retrieve. For stacks, the Original and Processed templates are always available. For change sets, the Original template is always available. After CloudFormation finishes creating the change set, the Processed template becomes available.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stagesAvailable: [TemplateStage]?
        /// Structure containing the template body. (For more information, go to Template Anatomy in the CloudFormation User Guide.) CloudFormation returns the same template that was used when the stack was created.
        public let templateBody: String?

        public init(stagesAvailable: [TemplateStage]? = nil, templateBody: String? = nil) {
            self.stagesAvailable = stagesAvailable
            self.templateBody = templateBody
        }

        private enum CodingKeys: String, CodingKey {
            case stagesAvailable = "StagesAvailable"
            case templateBody = "TemplateBody"
        }
    }

    public struct GetTemplateSummaryInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The name or the stack ID that's associated with the stack, which aren't always interchangeable. For running stacks, you can specify either the stack's name or its unique stack ID. For deleted stack, you must specify the unique stack ID. Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.
        public let stackName: String?
        /// The name or unique ID of the stack set from which the stack was created. Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.
        public let stackSetName: String?
        /// Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information about templates, see Template anatomy in the CloudFormation User Guide. Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.
        public let templateBody: String?
        /// Location of file containing the template body. The URL must point to a template (max size: 460,800 bytes) that's located in an Amazon S3 bucket or a Systems Manager document. For more information about templates, see Template anatomy in the CloudFormation User Guide. Conditional: You must specify only one of the following parameters: StackName, StackSetName, TemplateBody, or TemplateURL.
        public let templateURL: String?

        public init(callAs: CallAs? = nil, stackName: String? = nil, stackSetName: String? = nil, templateBody: String? = nil, templateURL: String? = nil) {
            self.callAs = callAs
            self.stackName = stackName
            self.stackSetName = stackSetName
            self.templateBody = templateBody
            self.templateURL = templateURL
        }

        public func validate(name: String) throws {
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
            try self.validate(self.stackSetName, name: "stackSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*(?::[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12})?$")
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case stackName = "StackName"
            case stackSetName = "StackSetName"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
        }
    }

    public struct GetTemplateSummaryOutput: AWSDecodableShape {
        /// The capabilities found within the template. If your template contains IAM resources, you must specify the CAPABILITY_IAM or CAPABILITY_NAMED_IAM value for this parameter when you use the CreateStack or UpdateStack actions with your template; otherwise, those actions return an InsufficientCapabilities error. For more information, see Acknowledging IAM Resources in CloudFormation Templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// The list of resources that generated the values in the Capabilities response element.
        public let capabilitiesReason: String?
        /// A list of the transforms that are declared in the template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var declaredTransforms: [String]?
        /// The value that's defined in the Description property of the template.
        public let description: String?
        /// The value that's defined for the Metadata property of the template.
        public let metadata: String?
        /// A list of parameter declarations that describe various properties for each parameter.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [ParameterDeclaration]?
        /// A list of resource identifier summaries that describe the target resources of an import operation and the properties you can provide during the import to identify the target resources. For example, BucketName is a possible identifier property for an AWS::S3::Bucket resource.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceIdentifierSummaries: [ResourceIdentifierSummary]?
        /// A list of all the template resource types that are defined in the template, such as AWS::EC2::Instance, AWS::Dynamo::Table, and Custom::MyCustomInstance.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceTypes: [String]?
        /// The Amazon Web Services template format version, which identifies the capabilities of the template.
        public let version: String?

        public init(capabilities: [Capability]? = nil, capabilitiesReason: String? = nil, declaredTransforms: [String]? = nil, description: String? = nil, metadata: String? = nil, parameters: [ParameterDeclaration]? = nil, resourceIdentifierSummaries: [ResourceIdentifierSummary]? = nil, resourceTypes: [String]? = nil, version: String? = nil) {
            self.capabilities = capabilities
            self.capabilitiesReason = capabilitiesReason
            self.declaredTransforms = declaredTransforms
            self.description = description
            self.metadata = metadata
            self.parameters = parameters
            self.resourceIdentifierSummaries = resourceIdentifierSummaries
            self.resourceTypes = resourceTypes
            self.version = version
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case capabilitiesReason = "CapabilitiesReason"
            case declaredTransforms = "DeclaredTransforms"
            case description = "Description"
            case metadata = "Metadata"
            case parameters = "Parameters"
            case resourceIdentifierSummaries = "ResourceIdentifierSummaries"
            case resourceTypes = "ResourceTypes"
            case version = "Version"
        }
    }

    public struct ImportStacksToStackSetInput: AWSEncodableShape {
        /// By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   For service managed stack sets, specify DELEGATED_ADMIN.
        public let callAs: CallAs?
        /// A unique, user defined, identifier for the stack set operation.
        public let operationId: String?
        public let operationPreferences: StackSetOperationPreferences?
        /// The list of OU ID's to which the stacks being imported has to be mapped as deployment target.
        @OptionalCustomCoding<StandardArrayCoder>
        public var organizationalUnitIds: [String]?
        /// The IDs of the stacks you are importing into a stack set. You import up to 10 stacks per stack set at a time. Specify either StackIds or StackIdsUrl.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackIds: [String]?
        /// The Amazon S3 URL which contains list of stack ids to be inputted. Specify either StackIds or StackIdsUrl.
        public let stackIdsUrl: String?
        /// The name of the stack set. The name must be unique in the Region where you create your stack set.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, operationId: String? = ImportStacksToStackSetInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, organizationalUnitIds: [String]? = nil, stackIds: [String]? = nil, stackIdsUrl: String? = nil, stackSetName: String) {
            self.callAs = callAs
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.organizationalUnitIds = organizationalUnitIds
            self.stackIds = stackIds
            self.stackIdsUrl = stackIdsUrl
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.organizationalUnitIds?.forEach {
                try validate($0, name: "organizationalUnitIds[]", parent: name, pattern: "^(ou-[a-z0-9]{4,32}-[a-z0-9]{8,32}|r-[a-z0-9]{4,32})$")
            }
            try self.validate(self.stackIdsUrl, name: "stackIdsUrl", parent: name, max: 5120)
            try self.validate(self.stackIdsUrl, name: "stackIdsUrl", parent: name, min: 1)
            try self.validate(self.stackIdsUrl, name: "stackIdsUrl", parent: name, pattern: "^(s3://|http(s?)://).+$")
            try self.validate(self.stackSetName, name: "stackSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*(?::[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12})?$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case organizationalUnitIds = "OrganizationalUnitIds"
            case stackIds = "StackIds"
            case stackIdsUrl = "StackIdsUrl"
            case stackSetName = "StackSetName"
        }
    }

    public struct ImportStacksToStackSetOutput: AWSDecodableShape {
        /// The unique identifier for the stack set operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct ListChangeSetsInput: AWSEncodableShape {
        /// A string (provided by the ListChangeSets response output) that identifies the next page of change sets that you want to retrieve.
        public let nextToken: String?
        /// The name or the Amazon Resource Name (ARN) of the stack for which you want to list change sets.
        public let stackName: String

        public init(nextToken: String? = nil, stackName: String) {
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct ListChangeSetsOutput: AWSDecodableShape {
        /// If the output exceeds 1 MB, a string that identifies the next page of change sets. If there is no additional page, this value is null.
        public let nextToken: String?
        /// A list of ChangeSetSummary structures that provides the ID and status of each change set for the specified stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var summaries: [ChangeSetSummary]?

        public init(nextToken: String? = nil, summaries: [ChangeSetSummary]? = nil) {
            self.nextToken = nextToken
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case summaries = "Summaries"
        }
    }

    public struct ListExportsInput: AWSEncodableShape {
        /// A string (provided by the ListExports response output) that identifies the next page of exported output values that you asked to retrieve.
        public let nextToken: String?

        public init(nextToken: String? = nil) {
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
        }
    }

    public struct ListExportsOutput: AWSDecodableShape {
        /// The output for the ListExports action.
        @OptionalCustomCoding<StandardArrayCoder>
        public var exports: [Export]?
        /// If the output exceeds 100 exported output values, a string that identifies the next page of exports. If there is no additional page, this value is null.
        public let nextToken: String?

        public init(exports: [Export]? = nil, nextToken: String? = nil) {
            self.exports = exports
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case exports = "Exports"
            case nextToken = "NextToken"
        }
    }

    public struct ListImportsInput: AWSEncodableShape {
        /// The name of the exported output value. CloudFormation returns the stack names that are importing this value.
        public let exportName: String
        /// A string (provided by the ListImports response output) that identifies the next page of stacks that are importing the specified exported output value.
        public let nextToken: String?

        public init(exportName: String, nextToken: String? = nil) {
            self.exportName = exportName
            self.nextToken = nextToken
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case exportName = "ExportName"
            case nextToken = "NextToken"
        }
    }

    public struct ListImportsOutput: AWSDecodableShape {
        /// A list of stack names that are importing the specified exported output value.
        @OptionalCustomCoding<StandardArrayCoder>
        public var imports: [String]?
        /// A string that identifies the next page of exports. If there is no additional page, this value is null.
        public let nextToken: String?

        public init(imports: [String]? = nil, nextToken: String? = nil) {
            self.imports = imports
            self.nextToken = nextToken
        }

        private enum CodingKeys: String, CodingKey {
            case imports = "Imports"
            case nextToken = "NextToken"
        }
    }

    public struct ListStackInstancesInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The filter to apply to stack instances
        @OptionalCustomCoding<StandardArrayCoder>
        public var filters: [StackInstanceFilter]?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous request didn't return all the remaining results, the response's NextToken parameter value is set to a token. To retrieve the next set of results, call ListStackInstances again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The name of the Amazon Web Services account that you want to list stack instances for.
        public let stackInstanceAccount: String?
        /// The name of the Region where you want to list stack instances.
        public let stackInstanceRegion: String?
        /// The name or unique ID of the stack set that you want to list stack instances for.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, filters: [StackInstanceFilter]? = nil, maxResults: Int? = nil, nextToken: String? = nil, stackInstanceAccount: String? = nil, stackInstanceRegion: String? = nil, stackSetName: String) {
            self.callAs = callAs
            self.filters = filters
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.stackInstanceAccount = stackInstanceAccount
            self.stackInstanceRegion = stackInstanceRegion
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.filters?.forEach {
                try $0.validate(name: "\(name).filters[]")
            }
            try self.validate(self.filters, name: "filters", parent: name, max: 2)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.stackInstanceAccount, name: "stackInstanceAccount", parent: name, pattern: "^[0-9]{12}$")
            try self.validate(self.stackInstanceRegion, name: "stackInstanceRegion", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case filters = "Filters"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case stackInstanceAccount = "StackInstanceAccount"
            case stackInstanceRegion = "StackInstanceRegion"
            case stackSetName = "StackSetName"
        }
    }

    public struct ListStackInstancesOutput: AWSDecodableShape {
        /// If the request doesn't return all the remaining results, NextToken is set to a token. To retrieve the next set of results, call ListStackInstances again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// A list of StackInstanceSummary structures that contain information about the specified stack instances.
        @OptionalCustomCoding<StandardArrayCoder>
        public var summaries: [StackInstanceSummary]?

        public init(nextToken: String? = nil, summaries: [StackInstanceSummary]? = nil) {
            self.nextToken = nextToken
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case summaries = "Summaries"
        }
    }

    public struct ListStackResourcesInput: AWSEncodableShape {
        /// A string that identifies the next page of stack resources that you want to retrieve.
        public let nextToken: String?
        /// The name or the unique stack ID that is associated with the stack, which aren't always interchangeable:   Running stacks: You can specify either the stack's name or its unique stack ID.   Deleted stacks: You must specify the unique stack ID.   Default: There is no default value.
        public let stackName: String

        public init(nextToken: String? = nil, stackName: String) {
            self.nextToken = nextToken
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackName = "StackName"
        }
    }

    public struct ListStackResourcesOutput: AWSDecodableShape {
        /// If the output exceeds 1 MB, a string that identifies the next page of stack resources. If no additional page exists, this value is null.
        public let nextToken: String?
        /// A list of StackResourceSummary structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackResourceSummaries: [StackResourceSummary]?

        public init(nextToken: String? = nil, stackResourceSummaries: [StackResourceSummary]? = nil) {
            self.nextToken = nextToken
            self.stackResourceSummaries = stackResourceSummaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackResourceSummaries = "StackResourceSummaries"
        }
    }

    public struct ListStackSetOperationResultsInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The filter to apply to operation results.
        @OptionalCustomCoding<StandardArrayCoder>
        public var filters: [OperationResultFilter]?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous request didn't return all the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call ListStackSetOperationResults again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The ID of the stack set operation.
        public let operationId: String
        /// The name or unique ID of the stack set that you want to get operation results for.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, filters: [OperationResultFilter]? = nil, maxResults: Int? = nil, nextToken: String? = nil, operationId: String, stackSetName: String) {
            self.callAs = callAs
            self.filters = filters
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.operationId = operationId
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.filters?.forEach {
                try $0.validate(name: "\(name).filters[]")
            }
            try self.validate(self.filters, name: "filters", parent: name, max: 1)
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case filters = "Filters"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case operationId = "OperationId"
            case stackSetName = "StackSetName"
        }
    }

    public struct ListStackSetOperationResultsOutput: AWSDecodableShape {
        /// If the request doesn't return all results, NextToken is set to a token. To retrieve the next set of results, call ListOperationResults again and assign that token to the request object's NextToken parameter. If there are no remaining results, NextToken is set to null.
        public let nextToken: String?
        /// A list of StackSetOperationResultSummary structures that contain information about the specified operation results, for accounts and Amazon Web Services Regions that are included in the operation.
        @OptionalCustomCoding<StandardArrayCoder>
        public var summaries: [StackSetOperationResultSummary]?

        public init(nextToken: String? = nil, summaries: [StackSetOperationResultSummary]? = nil) {
            self.nextToken = nextToken
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case summaries = "Summaries"
        }
    }

    public struct ListStackSetOperationsInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous paginated request didn't return all of the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call ListStackSetOperations again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The name or unique ID of the stack set that you want to get operation summaries for.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, maxResults: Int? = nil, nextToken: String? = nil, stackSetName: String) {
            self.callAs = callAs
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case stackSetName = "StackSetName"
        }
    }

    public struct ListStackSetOperationsOutput: AWSDecodableShape {
        /// If the request doesn't return all results, NextToken is set to a token. To retrieve the next set of results, call ListOperationResults again and assign that token to the request object's NextToken parameter. If there are no remaining results, NextToken is set to null.
        public let nextToken: String?
        /// A list of StackSetOperationSummary structures that contain summary information about operations for the specified stack set.
        @OptionalCustomCoding<StandardArrayCoder>
        public var summaries: [StackSetOperationSummary]?

        public init(nextToken: String? = nil, summaries: [StackSetOperationSummary]? = nil) {
            self.nextToken = nextToken
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case summaries = "Summaries"
        }
    }

    public struct ListStackSetsInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous paginated request didn't return all the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call ListStackSets again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The status of the stack sets that you want to get summary information about.
        public let status: StackSetStatus?

        public init(callAs: CallAs? = nil, maxResults: Int? = nil, nextToken: String? = nil, status: StackSetStatus? = nil) {
            self.callAs = callAs
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.status = status
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case status = "Status"
        }
    }

    public struct ListStackSetsOutput: AWSDecodableShape {
        /// If the request doesn't return all of the remaining results, NextToken is set to a token. To retrieve the next set of results, call ListStackInstances again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// A list of StackSetSummary structures that contain information about the user's stack sets.
        @OptionalCustomCoding<StandardArrayCoder>
        public var summaries: [StackSetSummary]?

        public init(nextToken: String? = nil, summaries: [StackSetSummary]? = nil) {
            self.nextToken = nextToken
            self.summaries = summaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case summaries = "Summaries"
        }
    }

    public struct ListStacksInput: AWSEncodableShape {
        /// A string that identifies the next page of stacks that you want to retrieve.
        public let nextToken: String?
        /// Stack status to use as a filter. Specify one or more stack status codes to list only stacks with the specified status codes. For a complete list of stack status codes, see the StackStatus parameter of the Stack data type.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackStatusFilter: [StackStatus]?

        public init(nextToken: String? = nil, stackStatusFilter: [StackStatus]? = nil) {
            self.nextToken = nextToken
            self.stackStatusFilter = stackStatusFilter
        }

        public func validate(name: String) throws {
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackStatusFilter = "StackStatusFilter"
        }
    }

    public struct ListStacksOutput: AWSDecodableShape {
        /// If the output exceeds 1 MB in size, a string that identifies the next page of stacks. If no additional page exists, this value is null.
        public let nextToken: String?
        /// A list of StackSummary structures containing information about the specified stacks.
        @OptionalCustomCoding<StandardArrayCoder>
        public var stackSummaries: [StackSummary]?

        public init(nextToken: String? = nil, stackSummaries: [StackSummary]? = nil) {
            self.nextToken = nextToken
            self.stackSummaries = stackSummaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case stackSummaries = "StackSummaries"
        }
    }

    public struct ListTypeRegistrationsInput: AWSEncodableShape {
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous paginated request didn't return all the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The current status of the extension registration request. The default is IN_PROGRESS.
        public let registrationStatusFilter: RegistrationStatus?
        /// The kind of extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let type: RegistryType?
        /// The Amazon Resource Name (ARN) of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeArn: String?
        /// The name of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeName: String?

        public init(maxResults: Int? = nil, nextToken: String? = nil, registrationStatusFilter: RegistrationStatus? = nil, type: RegistryType? = nil, typeArn: String? = nil, typeName: String? = nil) {
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.registrationStatusFilter = registrationStatusFilter
            self.type = type
            self.typeArn = typeArn
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.typeArn, name: "typeArn", parent: name, max: 1024)
            try self.validate(self.typeArn, name: "typeArn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case registrationStatusFilter = "RegistrationStatusFilter"
            case type = "Type"
            case typeArn = "TypeArn"
            case typeName = "TypeName"
        }
    }

    public struct ListTypeRegistrationsOutput: AWSDecodableShape {
        /// If the request doesn't return all the remaining results, NextToken is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// A list of extension registration tokens. Use  DescribeTypeRegistration to return detailed information about a type registration request.
        @OptionalCustomCoding<StandardArrayCoder>
        public var registrationTokenList: [String]?

        public init(nextToken: String? = nil, registrationTokenList: [String]? = nil) {
            self.nextToken = nextToken
            self.registrationTokenList = registrationTokenList
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case registrationTokenList = "RegistrationTokenList"
        }
    }

    public struct ListTypeVersionsInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension for which you want version summary information. Conditional: You must specify either TypeName and Type, or Arn.
        public let arn: String?
        /// The deprecation status of the extension versions that you want to get summary information about. Valid values include:    LIVE: The extension version is registered and can be used in CloudFormation operations, dependent on its provisioning behavior and visibility scope.    DEPRECATED: The extension version has been deregistered and can no longer be used in CloudFormation operations.   The default is LIVE.
        public let deprecatedStatus: DeprecatedStatus?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous paginated request didn't return all of the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// The publisher ID of the extension publisher. Extensions published by Amazon aren't assigned a publisher ID.
        public let publisherId: String?
        /// The kind of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let type: RegistryType?
        /// The name of the extension for which you want version summary information. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeName: String?

        public init(arn: String? = nil, deprecatedStatus: DeprecatedStatus? = nil, maxResults: Int? = nil, nextToken: String? = nil, publisherId: String? = nil, type: RegistryType? = nil, typeName: String? = nil) {
            self.arn = arn
            self.deprecatedStatus = deprecatedStatus
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.publisherId = publisherId
            self.type = type
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, max: 40)
            try self.validate(self.publisherId, name: "publisherId", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, pattern: "^[0-9a-zA-Z]{12,40}$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case deprecatedStatus = "DeprecatedStatus"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case publisherId = "PublisherId"
            case type = "Type"
            case typeName = "TypeName"
        }
    }

    public struct ListTypeVersionsOutput: AWSDecodableShape {
        /// If the request doesn't return all of the remaining results, NextToken is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// A list of TypeVersionSummary structures that contain information about the specified extension's versions.
        @OptionalCustomCoding<StandardArrayCoder>
        public var typeVersionSummaries: [TypeVersionSummary]?

        public init(nextToken: String? = nil, typeVersionSummaries: [TypeVersionSummary]? = nil) {
            self.nextToken = nextToken
            self.typeVersionSummaries = typeVersionSummaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case typeVersionSummaries = "TypeVersionSummaries"
        }
    }

    public struct ListTypesInput: AWSEncodableShape {
        /// The deprecation status of the extension that you want to get summary information about. Valid values include:    LIVE: The extension is registered for use in CloudFormation operations.    DEPRECATED: The extension has been deregistered and can no longer be used in CloudFormation operations.
        public let deprecatedStatus: DeprecatedStatus?
        /// Filter criteria to use in determining which extensions to return. Filters must be compatible with Visibility to return valid results. For example, specifying AWS_TYPES for Category and PRIVATE for Visibility returns an empty list of types, but specifying PUBLIC for Visibility returns the desired list.
        public let filters: TypeFilters?
        /// The maximum number of results to be returned with a single call. If the number of available results exceeds this maximum, the response includes a NextToken value that you can assign to the NextToken request parameter to get the next set of results.
        public let maxResults: Int?
        /// If the previous paginated request didn't return all the remaining results, the response object's NextToken parameter value is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If there are no remaining results, the previous response object's NextToken parameter is set to null.
        public let nextToken: String?
        /// For resource types, the provisioning behavior of the resource type. CloudFormation determines the provisioning type during registration, based on the types of handlers in the schema handler package submitted. Valid values include:    FULLY_MUTABLE: The resource type includes an update handler to process updates to the type during stack update operations.    IMMUTABLE: The resource type doesn't include an update handler, so the type can't be updated and must instead be replaced during stack update operations.    NON_PROVISIONABLE: The resource type doesn't include create, read, and delete handlers, and therefore can't actually be provisioned.   The default is FULLY_MUTABLE.
        public let provisioningType: ProvisioningType?
        /// The type of extension.
        public let type: RegistryType?
        /// The scope at which the extensions are visible and usable in CloudFormation operations. Valid values include:    PRIVATE: Extensions that are visible and usable within this account and region. This includes:   Private extensions you have registered in this account and region.   Public extensions that you have activated in this account and region.      PUBLIC: Extensions that are publicly visible and available to be activated within any Amazon Web Services account. This includes extensions from Amazon Web Services, in addition to third-party publishers.   The default is PRIVATE.
        public let visibility: Visibility?

        public init(deprecatedStatus: DeprecatedStatus? = nil, filters: TypeFilters? = nil, maxResults: Int? = nil, nextToken: String? = nil, provisioningType: ProvisioningType? = nil, type: RegistryType? = nil, visibility: Visibility? = nil) {
            self.deprecatedStatus = deprecatedStatus
            self.filters = filters
            self.maxResults = maxResults
            self.nextToken = nextToken
            self.provisioningType = provisioningType
            self.type = type
            self.visibility = visibility
        }

        public func validate(name: String) throws {
            try self.filters?.validate(name: "\(name).filters")
            try self.validate(self.maxResults, name: "maxResults", parent: name, max: 100)
            try self.validate(self.maxResults, name: "maxResults", parent: name, min: 1)
            try self.validate(self.nextToken, name: "nextToken", parent: name, max: 1024)
            try self.validate(self.nextToken, name: "nextToken", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case deprecatedStatus = "DeprecatedStatus"
            case filters = "Filters"
            case maxResults = "MaxResults"
            case nextToken = "NextToken"
            case provisioningType = "ProvisioningType"
            case type = "Type"
            case visibility = "Visibility"
        }
    }

    public struct ListTypesOutput: AWSDecodableShape {
        /// If the request doesn't return all the remaining results, NextToken is set to a token. To retrieve the next set of results, call this action again and assign that token to the request object's NextToken parameter. If the request returns all results, NextToken is set to null.
        public let nextToken: String?
        /// A list of TypeSummary structures that contain information about the specified extensions.
        @OptionalCustomCoding<StandardArrayCoder>
        public var typeSummaries: [TypeSummary]?

        public init(nextToken: String? = nil, typeSummaries: [TypeSummary]? = nil) {
            self.nextToken = nextToken
            self.typeSummaries = typeSummaries
        }

        private enum CodingKeys: String, CodingKey {
            case nextToken = "NextToken"
            case typeSummaries = "TypeSummaries"
        }
    }

    public struct LoggingConfig: AWSEncodableShape & AWSDecodableShape {
        /// The Amazon CloudWatch Logs group to which CloudFormation sends error logging information when invoking the extension's handlers.
        public let logGroupName: String
        /// The Amazon Resource Name (ARN) of the role that CloudFormation should assume when sending log entries to CloudWatch Logs.
        public let logRoleArn: String

        public init(logGroupName: String, logRoleArn: String) {
            self.logGroupName = logGroupName
            self.logRoleArn = logRoleArn
        }

        public func validate(name: String) throws {
            try self.validate(self.logGroupName, name: "logGroupName", parent: name, max: 512)
            try self.validate(self.logGroupName, name: "logGroupName", parent: name, min: 1)
            try self.validate(self.logGroupName, name: "logGroupName", parent: name, pattern: "^[\\.\\-_/#A-Za-z0-9]+$")
            try self.validate(self.logRoleArn, name: "logRoleArn", parent: name, max: 256)
            try self.validate(self.logRoleArn, name: "logRoleArn", parent: name, min: 1)
            try self.validate(self.logRoleArn, name: "logRoleArn", parent: name, pattern: "^arn:.+:iam::[0-9]{12}:role/.+$")
        }

        private enum CodingKeys: String, CodingKey {
            case logGroupName = "LogGroupName"
            case logRoleArn = "LogRoleArn"
        }
    }

    public struct ManagedExecution: AWSEncodableShape & AWSDecodableShape {
        /// When true, StackSets performs non-conflicting operations concurrently and queues conflicting operations. After conflicting operations finish, StackSets starts queued operations in request order.  If there are already running or queued operations, StackSets queues all incoming operations even if they are non-conflicting. You can't modify your stack set's execution configuration while there are running or queued operations for that stack set.  When false (default), StackSets performs one operation at a time in request order.
        public let active: Bool?

        public init(active: Bool? = nil) {
            self.active = active
        }

        private enum CodingKeys: String, CodingKey {
            case active = "Active"
        }
    }

    public struct ModuleInfo: AWSDecodableShape {
        /// A concatenated list of the logical IDs of the module or modules containing the resource. Modules are listed starting with the inner-most nested module, and separated by /. In the following example, the resource was created from a module, moduleA, that's nested inside a parent module, moduleB.  moduleA/moduleB  For more information, see Referencing resources in a module in the CloudFormation User Guide.
        public let logicalIdHierarchy: String?
        /// A concatenated list of the module type or types containing the resource. Module types are listed starting with the inner-most nested module, and separated by /. In the following example, the resource was created from a module of type AWS::First::Example::MODULE, that's nested inside a parent module of type AWS::Second::Example::MODULE.  AWS::First::Example::MODULE/AWS::Second::Example::MODULE
        public let typeHierarchy: String?

        public init(logicalIdHierarchy: String? = nil, typeHierarchy: String? = nil) {
            self.logicalIdHierarchy = logicalIdHierarchy
            self.typeHierarchy = typeHierarchy
        }

        private enum CodingKeys: String, CodingKey {
            case logicalIdHierarchy = "LogicalIdHierarchy"
            case typeHierarchy = "TypeHierarchy"
        }
    }

    public struct OperationResultFilter: AWSEncodableShape {
        /// The type of filter to apply.
        public let name: OperationResultFilterName?
        /// The value to filter by.
        public let values: String?

        public init(name: OperationResultFilterName? = nil, values: String? = nil) {
            self.name = name
            self.values = values
        }

        public func validate(name: String) throws {
            try self.validate(self.values, name: "values", parent: name, max: 9)
            try self.validate(self.values, name: "values", parent: name, min: 6)
            try self.validate(self.values, name: "values", parent: name, pattern: "^\\S{6,9}$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case values = "Values"
        }
    }

    public struct Output: AWSDecodableShape {
        /// User defined description associated with the output.
        public let description: String?
        /// The name of the export associated with the output.
        public let exportName: String?
        /// The key associated with the output.
        public let outputKey: String?
        /// The value associated with the output.
        public let outputValue: String?

        public init(description: String? = nil, exportName: String? = nil, outputKey: String? = nil, outputValue: String? = nil) {
            self.description = description
            self.exportName = exportName
            self.outputKey = outputKey
            self.outputValue = outputValue
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case exportName = "ExportName"
            case outputKey = "OutputKey"
            case outputValue = "OutputValue"
        }
    }

    public struct Parameter: AWSEncodableShape & AWSDecodableShape {
        /// The key associated with the parameter. If you don't specify a key and value for a particular parameter, CloudFormation uses the default value that's specified in your template.
        public let parameterKey: String?
        /// The input value associated with the parameter.
        public let parameterValue: String?
        /// Read-only. The value that corresponds to a SSM parameter key. This field is returned only for  SSM parameter types in the template.
        public let resolvedValue: String?
        /// During a stack update, use the existing parameter value that the stack is using for a given parameter key. If you specify true, do not specify a parameter value.
        public let usePreviousValue: Bool?

        public init(parameterKey: String? = nil, parameterValue: String? = nil, resolvedValue: String? = nil, usePreviousValue: Bool? = nil) {
            self.parameterKey = parameterKey
            self.parameterValue = parameterValue
            self.resolvedValue = resolvedValue
            self.usePreviousValue = usePreviousValue
        }

        private enum CodingKeys: String, CodingKey {
            case parameterKey = "ParameterKey"
            case parameterValue = "ParameterValue"
            case resolvedValue = "ResolvedValue"
            case usePreviousValue = "UsePreviousValue"
        }
    }

    public struct ParameterConstraints: AWSDecodableShape {
        /// A list of values that are permitted for a parameter.
        @OptionalCustomCoding<StandardArrayCoder>
        public var allowedValues: [String]?

        public init(allowedValues: [String]? = nil) {
            self.allowedValues = allowedValues
        }

        private enum CodingKeys: String, CodingKey {
            case allowedValues = "AllowedValues"
        }
    }

    public struct ParameterDeclaration: AWSDecodableShape {
        /// The default value of the parameter.
        public let defaultValue: String?
        /// The description that's associate with the parameter.
        public let description: String?
        /// Flag that indicates whether the parameter value is shown as plain text in logs and in the Amazon Web Services Management Console.
        public let noEcho: Bool?
        /// The criteria that CloudFormation uses to validate parameter values.
        public let parameterConstraints: ParameterConstraints?
        /// The name that's associated with the parameter.
        public let parameterKey: String?
        /// The type of parameter.
        public let parameterType: String?

        public init(defaultValue: String? = nil, description: String? = nil, noEcho: Bool? = nil, parameterConstraints: ParameterConstraints? = nil, parameterKey: String? = nil, parameterType: String? = nil) {
            self.defaultValue = defaultValue
            self.description = description
            self.noEcho = noEcho
            self.parameterConstraints = parameterConstraints
            self.parameterKey = parameterKey
            self.parameterType = parameterType
        }

        private enum CodingKeys: String, CodingKey {
            case defaultValue = "DefaultValue"
            case description = "Description"
            case noEcho = "NoEcho"
            case parameterConstraints = "ParameterConstraints"
            case parameterKey = "ParameterKey"
            case parameterType = "ParameterType"
        }
    }

    public struct PhysicalResourceIdContextKeyValuePair: AWSDecodableShape {
        /// The resource context key.
        public let key: String
        /// The resource context value.
        public let value: String

        public init(key: String, value: String) {
            self.key = key
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case key = "Key"
            case value = "Value"
        }
    }

    public struct PropertyDifference: AWSDecodableShape {
        /// The actual property value of the resource property.
        public let actualValue: String
        /// The type of property difference.    ADD: A value has been added to a resource property that's an array or list data type.    REMOVE: The property has been removed from the current resource configuration.    NOT_EQUAL: The current property value differs from its expected value (as defined in the stack template and any values specified as template parameters).
        public let differenceType: DifferenceType
        /// The expected property value of the resource property, as defined in the stack template and any values specified as template parameters.
        public let expectedValue: String
        /// The fully-qualified path to the resource property.
        public let propertyPath: String

        public init(actualValue: String, differenceType: DifferenceType, expectedValue: String, propertyPath: String) {
            self.actualValue = actualValue
            self.differenceType = differenceType
            self.expectedValue = expectedValue
            self.propertyPath = propertyPath
        }

        private enum CodingKeys: String, CodingKey {
            case actualValue = "ActualValue"
            case differenceType = "DifferenceType"
            case expectedValue = "ExpectedValue"
            case propertyPath = "PropertyPath"
        }
    }

    public struct PublishTypeInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension. Conditional: You must specify Arn, or TypeName and Type.
        public let arn: String?
        /// The version number to assign to this version of the extension. Use the following format, and adhere to semantic versioning when assigning a version number to your extension:  MAJOR.MINOR.PATCH  For more information, see Semantic Versioning 2.0.0. If you don't specify a version number, CloudFormation increments the version number by one minor version release. You cannot specify a version number the first time you publish a type. CloudFormation automatically sets the first version number to be 1.0.0.
        public let publicVersionNumber: String?
        /// The type of the extension. Conditional: You must specify Arn, or TypeName and Type.
        public let type: ThirdPartyType?
        /// The name of the extension. Conditional: You must specify Arn, or TypeName and Type.
        public let typeName: String?

        public init(arn: String? = nil, publicVersionNumber: String? = nil, type: ThirdPartyType? = nil, typeName: String? = nil) {
            self.arn = arn
            self.publicVersionNumber = publicVersionNumber
            self.type = type
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:[0-9]{12}:type/.+$")
            try self.validate(self.publicVersionNumber, name: "publicVersionNumber", parent: name, min: 5)
            try self.validate(self.publicVersionNumber, name: "publicVersionNumber", parent: name, pattern: "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(.*)$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case publicVersionNumber = "PublicVersionNumber"
            case type = "Type"
            case typeName = "TypeName"
        }
    }

    public struct PublishTypeOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) assigned to the public extension upon publication.
        public let publicTypeArn: String?

        public init(publicTypeArn: String? = nil) {
            self.publicTypeArn = publicTypeArn
        }

        private enum CodingKeys: String, CodingKey {
            case publicTypeArn = "PublicTypeArn"
        }
    }

    public struct RecordHandlerProgressInput: AWSEncodableShape {
        /// Reserved for use by the CloudFormation CLI.
        public let bearerToken: String
        /// Reserved for use by the CloudFormation CLI.
        public let clientRequestToken: String?
        /// Reserved for use by the CloudFormation CLI.
        public let currentOperationStatus: OperationStatus?
        /// Reserved for use by the CloudFormation CLI.
        public let errorCode: HandlerErrorCode?
        /// Reserved for use by the CloudFormation CLI.
        public let operationStatus: OperationStatus
        /// Reserved for use by the CloudFormation CLI.
        public let resourceModel: String?
        /// Reserved for use by the CloudFormation CLI.
        public let statusMessage: String?

        public init(bearerToken: String, clientRequestToken: String? = nil, currentOperationStatus: OperationStatus? = nil, errorCode: HandlerErrorCode? = nil, operationStatus: OperationStatus, resourceModel: String? = nil, statusMessage: String? = nil) {
            self.bearerToken = bearerToken
            self.clientRequestToken = clientRequestToken
            self.currentOperationStatus = currentOperationStatus
            self.errorCode = errorCode
            self.operationStatus = operationStatus
            self.resourceModel = resourceModel
            self.statusMessage = statusMessage
        }

        public func validate(name: String) throws {
            try self.validate(self.bearerToken, name: "bearerToken", parent: name, max: 128)
            try self.validate(self.bearerToken, name: "bearerToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.resourceModel, name: "resourceModel", parent: name, max: 16384)
            try self.validate(self.resourceModel, name: "resourceModel", parent: name, min: 1)
            try self.validate(self.statusMessage, name: "statusMessage", parent: name, max: 1024)
        }

        private enum CodingKeys: String, CodingKey {
            case bearerToken = "BearerToken"
            case clientRequestToken = "ClientRequestToken"
            case currentOperationStatus = "CurrentOperationStatus"
            case errorCode = "ErrorCode"
            case operationStatus = "OperationStatus"
            case resourceModel = "ResourceModel"
            case statusMessage = "StatusMessage"
        }
    }

    public struct RecordHandlerProgressOutput: AWSDecodableShape {
        public init() {}
    }

    public struct RegisterPublisherInput: AWSEncodableShape {
        /// Whether you accept the Terms and Conditions for publishing extensions in the CloudFormation registry. You must accept the terms and conditions in order to register to publish public extensions to the CloudFormation registry. The default is false.
        public let acceptTermsAndConditions: Bool?
        /// If you are using a Bitbucket or GitHub account for identity verification, the Amazon Resource Name (ARN) for your connection to that account. For more information, see Registering your account to publish CloudFormation extensions in the CloudFormation CLI User Guide.
        public let connectionArn: String?

        public init(acceptTermsAndConditions: Bool? = nil, connectionArn: String? = nil) {
            self.acceptTermsAndConditions = acceptTermsAndConditions
            self.connectionArn = connectionArn
        }

        public func validate(name: String) throws {
            try self.validate(self.connectionArn, name: "connectionArn", parent: name, max: 256)
            try self.validate(self.connectionArn, name: "connectionArn", parent: name, min: 1)
            try self.validate(self.connectionArn, name: "connectionArn", parent: name, pattern: "^arn:aws(-[\\w]+)*:.+:.+:[0-9]{12}:.+$")
        }

        private enum CodingKeys: String, CodingKey {
            case acceptTermsAndConditions = "AcceptTermsAndConditions"
            case connectionArn = "ConnectionArn"
        }
    }

    public struct RegisterPublisherOutput: AWSDecodableShape {
        /// The ID assigned this account by CloudFormation for publishing extensions.
        public let publisherId: String?

        public init(publisherId: String? = nil) {
            self.publisherId = publisherId
        }

        private enum CodingKeys: String, CodingKey {
            case publisherId = "PublisherId"
        }
    }

    public struct RegisterTypeInput: AWSEncodableShape {
        /// A unique identifier that acts as an idempotency key for this registration request. Specifying a client request token prevents CloudFormation from generating more than one version of an extension from the same registration request, even if the request is submitted multiple times.
        public let clientRequestToken: String?
        /// The Amazon Resource Name (ARN) of the IAM role for CloudFormation to assume when invoking the extension. For CloudFormation to assume the specified execution role, the role must contain a trust relationship with the CloudFormation service principle (resources.cloudformation.amazonaws.com). For more information about adding trust relationships, see Modifying a role trust policy in the Identity and Access Management User Guide. If your extension calls Amazon Web Services APIs in any of its handlers, you must create an  IAM execution role that includes the necessary permissions to call those Amazon Web Services APIs, and provision that execution role in your account. When CloudFormation needs to invoke the resource type handler, CloudFormation assumes this execution role to create a temporary session token, which it then passes to the resource type handler, thereby supplying your resource type with the appropriate credentials.
        public let executionRoleArn: String?
        /// Specifies logging configuration information for an extension.
        public let loggingConfig: LoggingConfig?
        /// A URL to the S3 bucket containing the extension project package that contains the necessary files for the extension you want to register. For information about generating a schema handler package for the extension you want to register, see submit in the CloudFormation CLI User Guide.  The user registering the extension must be able to access the package in the S3 bucket. That's, the user needs to have GetObject permissions for the schema handler package. For more information, see Actions, Resources, and Condition Keys for Amazon S3 in the Identity and Access Management User Guide.
        public let schemaHandlerPackage: String
        /// The kind of extension.
        public let type: RegistryType?
        /// The name of the extension being registered. We suggest that extension names adhere to the following patterns:   For resource types, company_or_organization::service::type.   For modules, company_or_organization::service::type::MODULE.   For hooks, MyCompany::Testing::MyTestHook.
        ///   The following organization namespaces are reserved and can't be used in your extension names:    Alexa     AMZN     Amazon     AWS     Custom     Dev
        public let typeName: String

        public init(clientRequestToken: String? = nil, executionRoleArn: String? = nil, loggingConfig: LoggingConfig? = nil, schemaHandlerPackage: String, type: RegistryType? = nil, typeName: String) {
            self.clientRequestToken = clientRequestToken
            self.executionRoleArn = executionRoleArn
            self.loggingConfig = loggingConfig
            self.schemaHandlerPackage = schemaHandlerPackage
            self.type = type
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, max: 256)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, min: 1)
            try self.validate(self.executionRoleArn, name: "executionRoleArn", parent: name, pattern: "^arn:.+:iam::[0-9]{12}:role/.+$")
            try self.loggingConfig?.validate(name: "\(name).loggingConfig")
            try self.validate(self.schemaHandlerPackage, name: "schemaHandlerPackage", parent: name, max: 4096)
            try self.validate(self.schemaHandlerPackage, name: "schemaHandlerPackage", parent: name, min: 1)
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case executionRoleArn = "ExecutionRoleArn"
            case loggingConfig = "LoggingConfig"
            case schemaHandlerPackage = "SchemaHandlerPackage"
            case type = "Type"
            case typeName = "TypeName"
        }
    }

    public struct RegisterTypeOutput: AWSDecodableShape {
        /// The identifier for this registration request. Use this registration token when calling  DescribeTypeRegistration , which returns information about the status and IDs of the extension registration.
        public let registrationToken: String?

        public init(registrationToken: String? = nil) {
            self.registrationToken = registrationToken
        }

        private enum CodingKeys: String, CodingKey {
            case registrationToken = "RegistrationToken"
        }
    }

    public struct RequiredActivatedType: AWSDecodableShape {
        /// The type name of the public extension. If you specified a TypeNameAlias when enabling the extension in this account and region, CloudFormation treats that alias as the extension's type name within the account and region, not the type name of the public extension. For more information, see Specifying aliases to refer to extensions in the CloudFormation User Guide.
        public let originalTypeName: String?
        /// The publisher ID of the extension publisher.
        public let publisherId: String?
        /// A list of the major versions of the extension type that the macro supports.
        @OptionalCustomCoding<StandardArrayCoder>
        public var supportedMajorVersions: [Int]?
        /// An alias assigned to the public extension, in this account and region. If you specify an alias for the extension, CloudFormation treats the alias as the extension type name within this account and region. You must use the alias to refer to the extension in your templates, API calls, and CloudFormation console.
        public let typeNameAlias: String?

        public init(originalTypeName: String? = nil, publisherId: String? = nil, supportedMajorVersions: [Int]? = nil, typeNameAlias: String? = nil) {
            self.originalTypeName = originalTypeName
            self.publisherId = publisherId
            self.supportedMajorVersions = supportedMajorVersions
            self.typeNameAlias = typeNameAlias
        }

        private enum CodingKeys: String, CodingKey {
            case originalTypeName = "OriginalTypeName"
            case publisherId = "PublisherId"
            case supportedMajorVersions = "SupportedMajorVersions"
            case typeNameAlias = "TypeNameAlias"
        }
    }

    public struct ResourceChange: AWSDecodableShape {
        /// The action that CloudFormation takes on the resource, such as Add (adds a new resource), Modify (changes a resource), Remove (deletes a resource), Import (imports a resource), or Dynamic (exact action for the resource can't be determined).
        public let action: ChangeAction?
        /// The change set ID of the nested change set.
        public let changeSetId: String?
        /// For the Modify action, a list of ResourceChangeDetail structures that describes the changes that CloudFormation will make to the resource.
        @OptionalCustomCoding<StandardArrayCoder>
        public var details: [ResourceChangeDetail]?
        /// The resource's logical ID, which is defined in the stack's template.
        public let logicalResourceId: String?
        /// Contains information about the module from which the resource was created, if the resource was created from a module included in the stack template.
        public let moduleInfo: ModuleInfo?
        /// The resource's physical ID (resource name). Resources that you are adding don't have physical IDs because they haven't been created.
        public let physicalResourceId: String?
        /// For the Modify action, indicates whether CloudFormation will replace the resource by creating a new one and deleting the old one. This value depends on the value of the RequiresRecreation property in the ResourceTargetDefinition structure. For example, if the RequiresRecreation field is Always and the Evaluation field is Static, Replacement is True. If the RequiresRecreation field is Always and the Evaluation field is Dynamic, Replacement is Conditionally. If you have multiple changes with different RequiresRecreation values, the Replacement value depends on the change with the most impact. A RequiresRecreation value of Always has the most impact, followed by Conditionally, and then Never.
        public let replacement: Replacement?
        /// The type of CloudFormation resource, such as AWS::S3::Bucket.
        public let resourceType: String?
        /// For the Modify action, indicates which resource attribute is triggering this update, such as a change in the resource attribute's Metadata, Properties, or Tags.
        @OptionalCustomCoding<StandardArrayCoder>
        public var scope: [ResourceAttribute]?

        public init(action: ChangeAction? = nil, changeSetId: String? = nil, details: [ResourceChangeDetail]? = nil, logicalResourceId: String? = nil, moduleInfo: ModuleInfo? = nil, physicalResourceId: String? = nil, replacement: Replacement? = nil, resourceType: String? = nil, scope: [ResourceAttribute]? = nil) {
            self.action = action
            self.changeSetId = changeSetId
            self.details = details
            self.logicalResourceId = logicalResourceId
            self.moduleInfo = moduleInfo
            self.physicalResourceId = physicalResourceId
            self.replacement = replacement
            self.resourceType = resourceType
            self.scope = scope
        }

        private enum CodingKeys: String, CodingKey {
            case action = "Action"
            case changeSetId = "ChangeSetId"
            case details = "Details"
            case logicalResourceId = "LogicalResourceId"
            case moduleInfo = "ModuleInfo"
            case physicalResourceId = "PhysicalResourceId"
            case replacement = "Replacement"
            case resourceType = "ResourceType"
            case scope = "Scope"
        }
    }

    public struct ResourceChangeDetail: AWSDecodableShape {
        /// The identity of the entity that triggered this change. This entity is a member of the group that's specified by the ChangeSource field. For example, if you modified the value of the KeyPairName parameter, the CausingEntity is the name of the parameter (KeyPairName). If the ChangeSource value is DirectModification, no value is given for CausingEntity.
        public let causingEntity: String?
        /// The group to which the CausingEntity value belongs. There are five entity groups:    ResourceReference entities are Ref intrinsic functions that refer to resources in the template, such as { "Ref" : "MyEC2InstanceResource" }.    ParameterReference entities are Ref intrinsic functions that get template parameter values, such as { "Ref" : "MyPasswordParameter" }.    ResourceAttribute entities are Fn::GetAtt intrinsic functions that get resource attribute values, such as { "Fn::GetAtt" : [ "MyEC2InstanceResource", "PublicDnsName" ] }.    DirectModification entities are changes that are made directly to the template.    Automatic entities are AWS::CloudFormation::Stack resource types, which are also known as nested stacks. If you made no changes to the AWS::CloudFormation::Stack resource, CloudFormation sets the ChangeSource to Automatic because the nested stack's template might have changed. Changes to a nested stack's template aren't visible to CloudFormation until you run an update on the parent stack.
        public let changeSource: ChangeSource?
        /// Indicates whether CloudFormation can determine the target value, and whether the target value will change before you execute a change set. For Static evaluations, CloudFormation can determine that the target value will change, and its value. For example, if you directly modify the InstanceType property of an EC2 instance, CloudFormation knows that this property value will change, and its value, so this is a Static evaluation. For Dynamic evaluations, can't determine the target value because it depends on the result of an intrinsic function, such as a Ref or Fn::GetAtt intrinsic function, when the stack is updated. For example, if your template includes a reference to a resource that's conditionally recreated, the value of the reference (the physical ID of the resource) might change, depending on if the resource is recreated. If the resource is recreated, it will have a new physical ID, so all references to that resource will also be updated.
        public let evaluation: EvaluationType?
        /// A ResourceTargetDefinition structure that describes the field that CloudFormation will change and whether the resource will be recreated.
        public let target: ResourceTargetDefinition?

        public init(causingEntity: String? = nil, changeSource: ChangeSource? = nil, evaluation: EvaluationType? = nil, target: ResourceTargetDefinition? = nil) {
            self.causingEntity = causingEntity
            self.changeSource = changeSource
            self.evaluation = evaluation
            self.target = target
        }

        private enum CodingKeys: String, CodingKey {
            case causingEntity = "CausingEntity"
            case changeSource = "ChangeSource"
            case evaluation = "Evaluation"
            case target = "Target"
        }
    }

    public struct ResourceIdentifierSummary: AWSDecodableShape {
        /// The logical IDs of the target resources of the specified ResourceType, as defined in the import template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var logicalResourceIds: [String]?
        /// The resource properties you can provide during the import to identify your target resources. For example, BucketName is a possible identifier property for AWS::S3::Bucket resources.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceIdentifiers: [String]?
        /// The template resource type of the target resources, such as AWS::S3::Bucket.
        public let resourceType: String?

        public init(logicalResourceIds: [String]? = nil, resourceIdentifiers: [String]? = nil, resourceType: String? = nil) {
            self.logicalResourceIds = logicalResourceIds
            self.resourceIdentifiers = resourceIdentifiers
            self.resourceType = resourceType
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceIds = "LogicalResourceIds"
            case resourceIdentifiers = "ResourceIdentifiers"
            case resourceType = "ResourceType"
        }
    }

    public struct ResourceTargetDefinition: AWSDecodableShape {
        /// Indicates which resource attribute is triggering this update, such as a change in the resource attribute's Metadata, Properties, or Tags.
        public let attribute: ResourceAttribute?
        /// If the Attribute value is Properties, the name of the property. For all other attributes, the value is null.
        public let name: String?
        /// If the Attribute value is Properties, indicates whether a change to this property causes the resource to be recreated. The value can be Never, Always, or Conditionally. To determine the conditions for a Conditionally recreation, see the update behavior for that property in the CloudFormation User Guide.
        public let requiresRecreation: RequiresRecreation?

        public init(attribute: ResourceAttribute? = nil, name: String? = nil, requiresRecreation: RequiresRecreation? = nil) {
            self.attribute = attribute
            self.name = name
            self.requiresRecreation = requiresRecreation
        }

        private enum CodingKeys: String, CodingKey {
            case attribute = "Attribute"
            case name = "Name"
            case requiresRecreation = "RequiresRecreation"
        }
    }

    public struct ResourceToImport: AWSEncodableShape {
        /// The logical ID of the target resource as specified in the template.
        public let logicalResourceId: String
        /// A key-value pair that identifies the target resource. The key is an identifier property (for example, BucketName for AWS::S3::Bucket resources) and the value is the actual property value (for example, MyS3Bucket).
        @CustomCoding<StandardDictionaryCoder>
        public var resourceIdentifier: [String: String]
        /// The type of resource to import into your stack, such as AWS::S3::Bucket. For a list of supported resource types, see Resources that support import operations in the CloudFormation User Guide.
        public let resourceType: String

        public init(logicalResourceId: String, resourceIdentifier: [String: String], resourceType: String) {
            self.logicalResourceId = logicalResourceId
            self.resourceIdentifier = resourceIdentifier
            self.resourceType = resourceType
        }

        public func validate(name: String) throws {
            try self.resourceIdentifier.forEach {
                try validate($0.key, name: "resourceIdentifier.key", parent: name, max: 2048)
                try validate($0.key, name: "resourceIdentifier.key", parent: name, min: 1)
                try validate($0.value, name: "resourceIdentifier[\"\($0.key)\"]", parent: name, max: 2048)
                try validate($0.value, name: "resourceIdentifier[\"\($0.key)\"]", parent: name, min: 1)
            }
            try self.validate(self.resourceIdentifier, name: "resourceIdentifier", parent: name, max: 256)
            try self.validate(self.resourceIdentifier, name: "resourceIdentifier", parent: name, min: 1)
            try self.validate(self.resourceType, name: "resourceType", parent: name, max: 256)
            try self.validate(self.resourceType, name: "resourceType", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case resourceIdentifier = "ResourceIdentifier"
            case resourceType = "ResourceType"
        }
    }

    public struct RollbackConfiguration: AWSEncodableShape & AWSDecodableShape {
        /// The amount of time, in minutes, during which CloudFormation should monitor all the rollback triggers after the stack creation or update operation deploys all necessary resources. The default is 0 minutes. If you specify a monitoring period but don't specify any rollback triggers, CloudFormation still waits the specified period of time before cleaning up old resources after update operations. You can use this monitoring period to perform any manual stack validation desired, and manually cancel the stack creation or update (using CancelUpdateStack, for example) as necessary. If you specify 0 for this parameter, CloudFormation still monitors the specified rollback triggers during stack creation and update operations. Then, for update operations, it begins disposing of old resources immediately once the operation completes.
        public let monitoringTimeInMinutes: Int?
        /// The triggers to monitor during stack creation or update actions. By default, CloudFormation saves the rollback triggers specified for a stack and applies them to any subsequent update operations for the stack, unless you specify otherwise. If you do specify rollback triggers for this parameter, those triggers replace any list of triggers previously specified for the stack. This means:   To use the rollback triggers previously specified for this stack, if any, don't specify this parameter.   To specify new or updated rollback triggers, you must specify all the triggers that you want used for this stack, even triggers you've specified before (for example, when creating the stack or during a previous stack update). Any triggers that you don't include in the updated list of triggers are no longer applied to the stack.   To remove all currently specified triggers, specify an empty list for this parameter.   If a specified trigger is missing, the entire stack operation fails and is rolled back.
        @OptionalCustomCoding<StandardArrayCoder>
        public var rollbackTriggers: [RollbackTrigger]?

        public init(monitoringTimeInMinutes: Int? = nil, rollbackTriggers: [RollbackTrigger]? = nil) {
            self.monitoringTimeInMinutes = monitoringTimeInMinutes
            self.rollbackTriggers = rollbackTriggers
        }

        public func validate(name: String) throws {
            try self.validate(self.monitoringTimeInMinutes, name: "monitoringTimeInMinutes", parent: name, max: 180)
            try self.validate(self.monitoringTimeInMinutes, name: "monitoringTimeInMinutes", parent: name, min: 0)
            try self.validate(self.rollbackTriggers, name: "rollbackTriggers", parent: name, max: 5)
        }

        private enum CodingKeys: String, CodingKey {
            case monitoringTimeInMinutes = "MonitoringTimeInMinutes"
            case rollbackTriggers = "RollbackTriggers"
        }
    }

    public struct RollbackStackInput: AWSEncodableShape {
        /// A unique identifier for this RollbackStack request.
        public let clientRequestToken: String?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management role that CloudFormation assumes to rollback the stack.
        public let roleARN: String?
        /// The name that's associated with the stack.
        public let stackName: String

        public init(clientRequestToken: String? = nil, roleARN: String? = nil, stackName: String) {
            self.clientRequestToken = clientRequestToken
            self.roleARN = roleARN
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case roleARN = "RoleARN"
            case stackName = "StackName"
        }
    }

    public struct RollbackStackOutput: AWSDecodableShape {
        /// Unique identifier of the stack.
        public let stackId: String?

        public init(stackId: String? = nil) {
            self.stackId = stackId
        }

        private enum CodingKeys: String, CodingKey {
            case stackId = "StackId"
        }
    }

    public struct RollbackTrigger: AWSEncodableShape & AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the rollback trigger. If a specified trigger is missing, the entire stack operation fails and is rolled back.
        public let arn: String
        /// The resource type of the rollback trigger. Specify either AWS::CloudWatch::Alarm or AWS::CloudWatch::CompositeAlarm resource types.
        public let type: String

        public init(arn: String, type: String) {
            self.arn = arn
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case type = "Type"
        }
    }

    public struct SetStackPolicyInput: AWSEncodableShape {
        /// The name or unique stack ID that you want to associate a policy with.
        public let stackName: String
        /// Structure containing the stack policy body. For more information, go to  Prevent updates to stack resources in the CloudFormation User Guide. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both.
        public let stackPolicyBody: String?
        /// Location of a file containing the stack policy. The URL must point to a policy (maximum size: 16 KB) located in an Amazon S3 bucket in the same Amazon Web Services Region as the stack. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both.
        public let stackPolicyURL: String?

        public init(stackName: String, stackPolicyBody: String? = nil, stackPolicyURL: String? = nil) {
            self.stackName = stackName
            self.stackPolicyBody = stackPolicyBody
            self.stackPolicyURL = stackPolicyURL
        }

        public func validate(name: String) throws {
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, max: 16384)
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, min: 1)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, max: 1350)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case stackName = "StackName"
            case stackPolicyBody = "StackPolicyBody"
            case stackPolicyURL = "StackPolicyURL"
        }
    }

    public struct SetTypeConfigurationInput: AWSEncodableShape {
        /// The configuration data for the extension, in this account and region. The configuration data must be formatted as JSON, and validate against the schema returned in the ConfigurationSchema response element of API_DescribeType. For more information, see Defining account-level configuration data for an extension in the CloudFormation CLI User Guide.
        public let configuration: String
        /// An alias by which to refer to this extension configuration data. Conditional: Specifying a configuration alias is required when setting a configuration for a resource type extension.
        public let configurationAlias: String?
        /// The type of extension. Conditional: You must specify ConfigurationArn, or Type and TypeName.
        public let type: ThirdPartyType?
        /// The Amazon Resource Name (ARN) for the extension, in this account and region. For public extensions, this will be the ARN assigned when you activate the type in this account and region. For private extensions, this will be the ARN assigned when you register the type in this account and region. Do not include the extension versions suffix at the end of the ARN. You can set the configuration for an extension, but not for a specific extension version.
        public let typeArn: String?
        /// The name of the extension. Conditional: You must specify ConfigurationArn, or Type and TypeName.
        public let typeName: String?

        public init(configuration: String, configurationAlias: String? = nil, type: ThirdPartyType? = nil, typeArn: String? = nil, typeName: String? = nil) {
            self.configuration = configuration
            self.configurationAlias = configurationAlias
            self.type = type
            self.typeArn = typeArn
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.configuration, name: "configuration", parent: name, max: 204_800)
            try self.validate(self.configuration, name: "configuration", parent: name, min: 1)
            try self.validate(self.configuration, name: "configuration", parent: name, pattern: "^[\\s\\S]+$")
            try self.validate(self.configurationAlias, name: "configurationAlias", parent: name, max: 256)
            try self.validate(self.configurationAlias, name: "configurationAlias", parent: name, min: 1)
            try self.validate(self.configurationAlias, name: "configurationAlias", parent: name, pattern: "^[a-zA-Z0-9]{1,256}$")
            try self.validate(self.typeArn, name: "typeArn", parent: name, max: 1024)
            try self.validate(self.typeArn, name: "typeArn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case configuration = "Configuration"
            case configurationAlias = "ConfigurationAlias"
            case type = "Type"
            case typeArn = "TypeArn"
            case typeName = "TypeName"
        }
    }

    public struct SetTypeConfigurationOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) for the configuration data, in this account and region. Conditional: You must specify ConfigurationArn, or Type and TypeName.
        public let configurationArn: String?

        public init(configurationArn: String? = nil) {
            self.configurationArn = configurationArn
        }

        private enum CodingKeys: String, CodingKey {
            case configurationArn = "ConfigurationArn"
        }
    }

    public struct SetTypeDefaultVersionInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension for which you want version summary information. Conditional: You must specify either TypeName and Type, or Arn.
        public let arn: String?
        /// The kind of extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let type: RegistryType?
        /// The name of the extension. Conditional: You must specify either TypeName and Type, or Arn.
        public let typeName: String?
        /// The ID of a specific version of the extension. The version ID is the value at the end of the Amazon Resource Name (ARN) assigned to the extension version when it is registered.
        public let versionId: String?

        public init(arn: String? = nil, type: RegistryType? = nil, typeName: String? = nil, versionId: String? = nil) {
            self.arn = arn
            self.type = type
            self.typeName = typeName
            self.versionId = versionId
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:[0-9]{12}:type/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
            try self.validate(self.versionId, name: "versionId", parent: name, max: 128)
            try self.validate(self.versionId, name: "versionId", parent: name, min: 1)
            try self.validate(self.versionId, name: "versionId", parent: name, pattern: "^[A-Za-z0-9-]+$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case type = "Type"
            case typeName = "TypeName"
            case versionId = "VersionId"
        }
    }

    public struct SetTypeDefaultVersionOutput: AWSDecodableShape {
        public init() {}
    }

    public struct SignalResourceInput: AWSEncodableShape {
        /// The logical ID of the resource that you want to signal. The logical ID is the name of the resource that given in the template.
        public let logicalResourceId: String
        /// The stack name or unique stack ID that includes the resource that you want to signal.
        public let stackName: String
        /// The status of the signal, which is either success or failure. A failure signal causes CloudFormation to immediately fail the stack creation or update.
        public let status: ResourceSignalStatus
        /// A unique ID of the signal. When you signal Amazon EC2 instances or Auto Scaling groups, specify the instance ID that you are signaling as the unique ID. If you send multiple signals to a single resource (such as signaling a wait condition), each signal requires a different unique ID.
        public let uniqueId: String

        public init(logicalResourceId: String, stackName: String, status: ResourceSignalStatus, uniqueId: String) {
            self.logicalResourceId = logicalResourceId
            self.stackName = stackName
            self.status = status
            self.uniqueId = uniqueId
        }

        public func validate(name: String) throws {
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
            try self.validate(self.uniqueId, name: "uniqueId", parent: name, max: 64)
            try self.validate(self.uniqueId, name: "uniqueId", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case logicalResourceId = "LogicalResourceId"
            case stackName = "StackName"
            case status = "Status"
            case uniqueId = "UniqueId"
        }
    }

    public struct Stack: AWSDecodableShape {
        /// The capabilities allowed in the stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// The unique ID of the change set.
        public let changeSetId: String?
        /// The time at which the stack was created.
        public let creationTime: Date
        /// The time the stack was deleted.
        public let deletionTime: Date?
        /// A user-defined description associated with the stack.
        public let description: String?
        /// Boolean to enable or disable rollback on stack creation failures:    true: disable rollback.    false: enable rollback.
        public let disableRollback: Bool?
        /// Information about whether a stack's actual configuration differs, or has drifted, from it's expected configuration, as defined in the stack template and any values specified as template parameters. For more information, see Detecting Unregulated Configuration Changes to Stacks and Resources.
        public let driftInformation: StackDriftInformation?
        /// Whether termination protection is enabled for the stack. For nested stacks, termination protection is set on the root stack and can't be changed directly on the nested stack. For more information, see Protecting a Stack From Being Deleted in the CloudFormation User Guide.
        public let enableTerminationProtection: Bool?
        /// The time the stack was last updated. This field will only be returned if the stack has been updated at least once.
        public let lastUpdatedTime: Date?
        /// Amazon SNS topic Amazon Resource Names (ARNs) to which stack related events are published.
        @OptionalCustomCoding<StandardArrayCoder>
        public var notificationARNs: [String]?
        /// A list of output structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var outputs: [Output]?
        /// A list of Parameter structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// For nested stacks--stacks created as resources for another stack--the stack ID of the direct parent of this stack. For the first level of nested stacks, the root stack is also the parent stack. For more information, see Working with Nested Stacks in the CloudFormation User Guide.
        public let parentId: String?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that's associated with the stack. During a stack operation, CloudFormation uses this role's credentials to make calls on your behalf.
        public let roleARN: String?
        /// The rollback triggers for CloudFormation to monitor during stack creation and updating operations, and for the specified monitoring period afterwards.
        public let rollbackConfiguration: RollbackConfiguration?
        /// For nested stacks--stacks created as resources for another stack--the stack ID of the top-level stack to which the nested stack ultimately belongs. For more information, see Working with Nested Stacks in the CloudFormation User Guide.
        public let rootId: String?
        /// Unique identifier of the stack.
        public let stackId: String?
        /// The name associated with the stack.
        public let stackName: String
        /// Current status of the stack.
        public let stackStatus: StackStatus
        /// Success/failure message associated with the stack status.
        public let stackStatusReason: String?
        /// A list of Tags that specify information about the stack.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// The amount of time within which stack creation should complete.
        public let timeoutInMinutes: Int?

        public init(capabilities: [Capability]? = nil, changeSetId: String? = nil, creationTime: Date, deletionTime: Date? = nil, description: String? = nil, disableRollback: Bool? = nil, driftInformation: StackDriftInformation? = nil, enableTerminationProtection: Bool? = nil, lastUpdatedTime: Date? = nil, notificationARNs: [String]? = nil, outputs: [Output]? = nil, parameters: [Parameter]? = nil, parentId: String? = nil, roleARN: String? = nil, rollbackConfiguration: RollbackConfiguration? = nil, rootId: String? = nil, stackId: String? = nil, stackName: String, stackStatus: StackStatus, stackStatusReason: String? = nil, tags: [Tag]? = nil, timeoutInMinutes: Int? = nil) {
            self.capabilities = capabilities
            self.changeSetId = changeSetId
            self.creationTime = creationTime
            self.deletionTime = deletionTime
            self.description = description
            self.disableRollback = disableRollback
            self.driftInformation = driftInformation
            self.enableTerminationProtection = enableTerminationProtection
            self.lastUpdatedTime = lastUpdatedTime
            self.notificationARNs = notificationARNs
            self.outputs = outputs
            self.parameters = parameters
            self.parentId = parentId
            self.roleARN = roleARN
            self.rollbackConfiguration = rollbackConfiguration
            self.rootId = rootId
            self.stackId = stackId
            self.stackName = stackName
            self.stackStatus = stackStatus
            self.stackStatusReason = stackStatusReason
            self.tags = tags
            self.timeoutInMinutes = timeoutInMinutes
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case changeSetId = "ChangeSetId"
            case creationTime = "CreationTime"
            case deletionTime = "DeletionTime"
            case description = "Description"
            case disableRollback = "DisableRollback"
            case driftInformation = "DriftInformation"
            case enableTerminationProtection = "EnableTerminationProtection"
            case lastUpdatedTime = "LastUpdatedTime"
            case notificationARNs = "NotificationARNs"
            case outputs = "Outputs"
            case parameters = "Parameters"
            case parentId = "ParentId"
            case roleARN = "RoleARN"
            case rollbackConfiguration = "RollbackConfiguration"
            case rootId = "RootId"
            case stackId = "StackId"
            case stackName = "StackName"
            case stackStatus = "StackStatus"
            case stackStatusReason = "StackStatusReason"
            case tags = "Tags"
            case timeoutInMinutes = "TimeoutInMinutes"
        }
    }

    public struct StackDriftInformation: AWSDecodableShape {
        /// Most recent time when a drift detection operation was initiated on the stack, or any of its individual resources that support drift detection.
        public let lastCheckTimestamp: Date?
        /// Status of the stack's actual configuration compared to its expected template configuration.    DRIFTED: The stack differs from its expected template configuration. A stack is considered to have drifted if one or more of its resources have drifted.    NOT_CHECKED: CloudFormation hasn't checked if the stack differs from its expected template configuration.    IN_SYNC: The stack's actual configuration matches its expected template configuration.    UNKNOWN: This value is reserved for future use.
        public let stackDriftStatus: StackDriftStatus

        public init(lastCheckTimestamp: Date? = nil, stackDriftStatus: StackDriftStatus) {
            self.lastCheckTimestamp = lastCheckTimestamp
            self.stackDriftStatus = stackDriftStatus
        }

        private enum CodingKeys: String, CodingKey {
            case lastCheckTimestamp = "LastCheckTimestamp"
            case stackDriftStatus = "StackDriftStatus"
        }
    }

    public struct StackDriftInformationSummary: AWSDecodableShape {
        /// Most recent time when a drift detection operation was initiated on the stack, or any of its individual resources that support drift detection.
        public let lastCheckTimestamp: Date?
        /// Status of the stack's actual configuration compared to its expected template configuration.    DRIFTED: The stack differs from its expected template configuration. A stack is considered to have drifted if one or more of its resources have drifted.    NOT_CHECKED: CloudFormation hasn't checked if the stack differs from its expected template configuration.    IN_SYNC: The stack's actual configuration matches its expected template configuration.    UNKNOWN: This value is reserved for future use.
        public let stackDriftStatus: StackDriftStatus

        public init(lastCheckTimestamp: Date? = nil, stackDriftStatus: StackDriftStatus) {
            self.lastCheckTimestamp = lastCheckTimestamp
            self.stackDriftStatus = stackDriftStatus
        }

        private enum CodingKeys: String, CodingKey {
            case lastCheckTimestamp = "LastCheckTimestamp"
            case stackDriftStatus = "StackDriftStatus"
        }
    }

    public struct StackEvent: AWSDecodableShape {
        /// The token passed to the operation that generated this event. All events triggered by a given stack operation are assigned the same client request token, which you can use to track operations. For example, if you execute a CreateStack operation with the token token1, then all the StackEvents generated by that operation will have ClientRequestToken set as token1. In the console, stack operations display the client request token on the Events tab. Stack operations that are initiated from the console use the token format Console-StackOperation-ID, which helps you easily identify the stack operation . For example, if you create a stack using the console, each stack event would be assigned the same token in the following format: Console-CreateStack-7f59c3cf-00d2-40c7-b2ff-e75db0987002.
        public let clientRequestToken: String?
        /// The unique ID of this event.
        public let eventId: String
        /// Specify the hook failure mode for non-compliant resources in the followings ways.    FAIL Stops provisioning resources.    WARN Allows provisioning to continue with a warning message.
        public let hookFailureMode: HookFailureMode?
        /// Invocation points are points in provisioning logic where hooks are initiated.
        public let hookInvocationPoint: HookInvocationPoint?
        /// Provides the status of the change set hook.
        public let hookStatus: HookStatus?
        /// Provides the reason for the hook status.
        public let hookStatusReason: String?
        /// The name of the hook.
        public let hookType: String?
        /// The logical name of the resource specified in the template.
        public let logicalResourceId: String?
        /// The name or unique identifier associated with the physical instance of the resource.
        public let physicalResourceId: String?
        /// BLOB of the properties used to create the resource.
        public let resourceProperties: String?
        /// Current status of the resource.
        public let resourceStatus: ResourceStatus?
        /// Success/failure message associated with the resource.
        public let resourceStatusReason: String?
        /// Type of resource. (For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide.)
        public let resourceType: String?
        /// The unique ID name of the instance of the stack.
        public let stackId: String
        /// The name associated with a stack.
        public let stackName: String
        /// Time the status was updated.
        public let timestamp: Date

        public init(clientRequestToken: String? = nil, eventId: String, hookFailureMode: HookFailureMode? = nil, hookInvocationPoint: HookInvocationPoint? = nil, hookStatus: HookStatus? = nil, hookStatusReason: String? = nil, hookType: String? = nil, logicalResourceId: String? = nil, physicalResourceId: String? = nil, resourceProperties: String? = nil, resourceStatus: ResourceStatus? = nil, resourceStatusReason: String? = nil, resourceType: String? = nil, stackId: String, stackName: String, timestamp: Date) {
            self.clientRequestToken = clientRequestToken
            self.eventId = eventId
            self.hookFailureMode = hookFailureMode
            self.hookInvocationPoint = hookInvocationPoint
            self.hookStatus = hookStatus
            self.hookStatusReason = hookStatusReason
            self.hookType = hookType
            self.logicalResourceId = logicalResourceId
            self.physicalResourceId = physicalResourceId
            self.resourceProperties = resourceProperties
            self.resourceStatus = resourceStatus
            self.resourceStatusReason = resourceStatusReason
            self.resourceType = resourceType
            self.stackId = stackId
            self.stackName = stackName
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case clientRequestToken = "ClientRequestToken"
            case eventId = "EventId"
            case hookFailureMode = "HookFailureMode"
            case hookInvocationPoint = "HookInvocationPoint"
            case hookStatus = "HookStatus"
            case hookStatusReason = "HookStatusReason"
            case hookType = "HookType"
            case logicalResourceId = "LogicalResourceId"
            case physicalResourceId = "PhysicalResourceId"
            case resourceProperties = "ResourceProperties"
            case resourceStatus = "ResourceStatus"
            case resourceStatusReason = "ResourceStatusReason"
            case resourceType = "ResourceType"
            case stackId = "StackId"
            case stackName = "StackName"
            case timestamp = "Timestamp"
        }
    }

    public struct StackInstance: AWSDecodableShape {
        /// [Self-managed permissions] The name of the Amazon Web Services account that the stack instance is associated with.
        public let account: String?
        /// Status of the stack instance's actual configuration compared to the expected template and parameter configuration of the stack set to which it belongs.    DRIFTED: The stack differs from the expected template and parameter configuration of the stack set to which it belongs. A stack instance is considered to have drifted if one or more of the resources in the associated stack have drifted.    NOT_CHECKED: CloudFormation hasn't checked if the stack instance differs from its expected stack set configuration.    IN_SYNC: The stack instance's actual configuration matches its expected stack set configuration.    UNKNOWN: This value is reserved for future use.
        public let driftStatus: StackDriftStatus?
        /// Most recent time when CloudFormation performed a drift detection operation on the stack instance. This value will be NULL for any stack instance on which drift detection hasn't yet been performed.
        public let lastDriftCheckTimestamp: Date?
        /// The last unique ID of a StackSet operation performed on a stack instance.
        public let lastOperationId: String?
        /// [Service-managed permissions] The organization root ID or organizational unit (OU) IDs that you specified for DeploymentTargets.
        public let organizationalUnitId: String?
        /// A list of parameters from the stack set template whose values have been overridden in this stack instance.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameterOverrides: [Parameter]?
        /// The name of the Amazon Web Services Region that the stack instance is associated with.
        public let region: String?
        /// The ID of the stack instance.
        public let stackId: String?
        /// The detailed status of the stack instance.
        public let stackInstanceStatus: StackInstanceComprehensiveStatus?
        /// The name or unique ID of the stack set that the stack instance is associated with.
        public let stackSetId: String?
        /// The status of the stack instance, in terms of its synchronization with its associated stack set.    INOPERABLE: A DeleteStackInstances operation has failed and left the stack in an unstable state. Stacks in this state are excluded from further UpdateStackSet operations. You might need to perform a DeleteStackInstances operation, with RetainStacks set to true, to delete the stack instance, and then delete the stack manually.    OUTDATED: The stack isn't currently up to date with the stack set because:   The associated stack failed during a CreateStackSet or UpdateStackSet operation.   The stack was part of a CreateStackSet or UpdateStackSet operation that failed or was stopped before the stack was created or updated.      CURRENT: The stack is currently up to date with the stack set.
        public let status: StackInstanceStatus?
        /// The explanation for the specific status code that's assigned to this stack instance.
        public let statusReason: String?

        public init(account: String? = nil, driftStatus: StackDriftStatus? = nil, lastDriftCheckTimestamp: Date? = nil, lastOperationId: String? = nil, organizationalUnitId: String? = nil, parameterOverrides: [Parameter]? = nil, region: String? = nil, stackId: String? = nil, stackInstanceStatus: StackInstanceComprehensiveStatus? = nil, stackSetId: String? = nil, status: StackInstanceStatus? = nil, statusReason: String? = nil) {
            self.account = account
            self.driftStatus = driftStatus
            self.lastDriftCheckTimestamp = lastDriftCheckTimestamp
            self.lastOperationId = lastOperationId
            self.organizationalUnitId = organizationalUnitId
            self.parameterOverrides = parameterOverrides
            self.region = region
            self.stackId = stackId
            self.stackInstanceStatus = stackInstanceStatus
            self.stackSetId = stackSetId
            self.status = status
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case account = "Account"
            case driftStatus = "DriftStatus"
            case lastDriftCheckTimestamp = "LastDriftCheckTimestamp"
            case lastOperationId = "LastOperationId"
            case organizationalUnitId = "OrganizationalUnitId"
            case parameterOverrides = "ParameterOverrides"
            case region = "Region"
            case stackId = "StackId"
            case stackInstanceStatus = "StackInstanceStatus"
            case stackSetId = "StackSetId"
            case status = "Status"
            case statusReason = "StatusReason"
        }
    }

    public struct StackInstanceComprehensiveStatus: AWSDecodableShape {
        ///    CANCELLED: The operation in the specified account and Region has been canceled. This is either because a user has stopped the stack set operation, or because the failure tolerance of the stack set operation has been exceeded.    FAILED: The operation in the specified account and Region failed. If the stack set operation fails in enough accounts within a Region, the failure tolerance for the stack set operation as a whole might be exceeded.    INOPERABLE: A DeleteStackInstances operation has failed and left the stack in an unstable state. Stacks in this state are excluded from further UpdateStackSet operations. You might need to perform a DeleteStackInstances operation, with RetainStacks set to true, to delete the stack instance, and then delete the stack manually.    PENDING: The operation in the specified account and Region has yet to start.    RUNNING: The operation in the specified account and Region is currently in progress.    SUCCEEDED: The operation in the specified account and Region completed successfully.
        public let detailedStatus: StackInstanceDetailedStatus?

        public init(detailedStatus: StackInstanceDetailedStatus? = nil) {
            self.detailedStatus = detailedStatus
        }

        private enum CodingKeys: String, CodingKey {
            case detailedStatus = "DetailedStatus"
        }
    }

    public struct StackInstanceFilter: AWSEncodableShape {
        /// The type of filter to apply.
        public let name: StackInstanceFilterName?
        /// The status to filter by.
        public let values: String?

        public init(name: StackInstanceFilterName? = nil, values: String? = nil) {
            self.name = name
            self.values = values
        }

        public func validate(name: String) throws {
            try self.validate(self.values, name: "values", parent: name, max: 128)
            try self.validate(self.values, name: "values", parent: name, min: 1)
            try self.validate(self.values, name: "values", parent: name, pattern: "^\\S{1,128}$")
        }

        private enum CodingKeys: String, CodingKey {
            case name = "Name"
            case values = "Values"
        }
    }

    public struct StackInstanceSummary: AWSDecodableShape {
        /// [Self-managed permissions] The name of the Amazon Web Services account that the stack instance is associated with.
        public let account: String?
        /// Status of the stack instance's actual configuration compared to the expected template and parameter configuration of the stack set to which it belongs.    DRIFTED: The stack differs from the expected template and parameter configuration of the stack set to which it belongs. A stack instance is considered to have drifted if one or more of the resources in the associated stack have drifted.    NOT_CHECKED: CloudFormation hasn't checked if the stack instance differs from its expected stack set configuration.    IN_SYNC: The stack instance's actual configuration matches its expected stack set configuration.    UNKNOWN: This value is reserved for future use.
        public let driftStatus: StackDriftStatus?
        /// Most recent time when CloudFormation performed a drift detection operation on the stack instance. This value will be NULL for any stack instance on which drift detection hasn't yet been performed.
        public let lastDriftCheckTimestamp: Date?
        /// The last unique ID of a StackSet operation performed on a stack instance.
        public let lastOperationId: String?
        /// [Service-managed permissions] The organization root ID or organizational unit (OU) IDs that you specified for DeploymentTargets.
        public let organizationalUnitId: String?
        /// The name of the Amazon Web Services Region that the stack instance is associated with.
        public let region: String?
        /// The ID of the stack instance.
        public let stackId: String?
        /// The detailed status of the stack instance.
        public let stackInstanceStatus: StackInstanceComprehensiveStatus?
        /// The name or unique ID of the stack set that the stack instance is associated with.
        public let stackSetId: String?
        /// The status of the stack instance, in terms of its synchronization with its associated stack set.    INOPERABLE: A DeleteStackInstances operation has failed and left the stack in an unstable state. Stacks in this state are excluded from further UpdateStackSet operations. You might need to perform a DeleteStackInstances operation, with RetainStacks set to true, to delete the stack instance, and then delete the stack manually.    OUTDATED: The stack isn't currently up to date with the stack set because:   The associated stack failed during a CreateStackSet or UpdateStackSet operation.   The stack was part of a CreateStackSet or UpdateStackSet operation that failed or was stopped before the stack was created or updated.      CURRENT: The stack is currently up to date with the stack set.
        public let status: StackInstanceStatus?
        /// The explanation for the specific status code assigned to this stack instance.
        public let statusReason: String?

        public init(account: String? = nil, driftStatus: StackDriftStatus? = nil, lastDriftCheckTimestamp: Date? = nil, lastOperationId: String? = nil, organizationalUnitId: String? = nil, region: String? = nil, stackId: String? = nil, stackInstanceStatus: StackInstanceComprehensiveStatus? = nil, stackSetId: String? = nil, status: StackInstanceStatus? = nil, statusReason: String? = nil) {
            self.account = account
            self.driftStatus = driftStatus
            self.lastDriftCheckTimestamp = lastDriftCheckTimestamp
            self.lastOperationId = lastOperationId
            self.organizationalUnitId = organizationalUnitId
            self.region = region
            self.stackId = stackId
            self.stackInstanceStatus = stackInstanceStatus
            self.stackSetId = stackSetId
            self.status = status
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case account = "Account"
            case driftStatus = "DriftStatus"
            case lastDriftCheckTimestamp = "LastDriftCheckTimestamp"
            case lastOperationId = "LastOperationId"
            case organizationalUnitId = "OrganizationalUnitId"
            case region = "Region"
            case stackId = "StackId"
            case stackInstanceStatus = "StackInstanceStatus"
            case stackSetId = "StackSetId"
            case status = "Status"
            case statusReason = "StatusReason"
        }
    }

    public struct StackResource: AWSDecodableShape {
        /// User defined description associated with the resource.
        public let description: String?
        /// Information about whether the resource's actual configuration differs, or has drifted, from its expected configuration, as defined in the stack template and any values specified as template parameters. For more information, see Detecting Unregulated Configuration Changes to Stacks and Resources.
        public let driftInformation: StackResourceDriftInformation?
        /// The logical name of the resource specified in the template.
        public let logicalResourceId: String
        /// Contains information about the module from which the resource was created, if the resource was created from a module included in the stack template.
        public let moduleInfo: ModuleInfo?
        /// The name or unique identifier that corresponds to a physical instance ID of a resource supported by CloudFormation.
        public let physicalResourceId: String?
        /// Current status of the resource.
        public let resourceStatus: ResourceStatus
        /// Success/failure message associated with the resource.
        public let resourceStatusReason: String?
        /// Type of resource. For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide.
        public let resourceType: String
        /// Unique identifier of the stack.
        public let stackId: String?
        /// The name associated with the stack.
        public let stackName: String?
        /// Time the status was updated.
        public let timestamp: Date

        public init(description: String? = nil, driftInformation: StackResourceDriftInformation? = nil, logicalResourceId: String, moduleInfo: ModuleInfo? = nil, physicalResourceId: String? = nil, resourceStatus: ResourceStatus, resourceStatusReason: String? = nil, resourceType: String, stackId: String? = nil, stackName: String? = nil, timestamp: Date) {
            self.description = description
            self.driftInformation = driftInformation
            self.logicalResourceId = logicalResourceId
            self.moduleInfo = moduleInfo
            self.physicalResourceId = physicalResourceId
            self.resourceStatus = resourceStatus
            self.resourceStatusReason = resourceStatusReason
            self.resourceType = resourceType
            self.stackId = stackId
            self.stackName = stackName
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case driftInformation = "DriftInformation"
            case logicalResourceId = "LogicalResourceId"
            case moduleInfo = "ModuleInfo"
            case physicalResourceId = "PhysicalResourceId"
            case resourceStatus = "ResourceStatus"
            case resourceStatusReason = "ResourceStatusReason"
            case resourceType = "ResourceType"
            case stackId = "StackId"
            case stackName = "StackName"
            case timestamp = "Timestamp"
        }
    }

    public struct StackResourceDetail: AWSDecodableShape {
        /// User defined description associated with the resource.
        public let description: String?
        /// Information about whether the resource's actual configuration differs, or has drifted, from its expected configuration, as defined in the stack template and any values specified as template parameters. For more information, see Detecting Unregulated Configuration Changes to Stacks and Resources.
        public let driftInformation: StackResourceDriftInformation?
        /// Time the status was updated.
        public let lastUpdatedTimestamp: Date
        /// The logical name of the resource specified in the template.
        public let logicalResourceId: String
        /// The content of the Metadata attribute declared for the resource. For more information, see Metadata Attribute in the CloudFormation User Guide.
        public let metadata: String?
        /// Contains information about the module from which the resource was created, if the resource was created from a module included in the stack template.
        public let moduleInfo: ModuleInfo?
        /// The name or unique identifier that corresponds to a physical instance ID of a resource supported by CloudFormation.
        public let physicalResourceId: String?
        /// Current status of the resource.
        public let resourceStatus: ResourceStatus
        /// Success/failure message associated with the resource.
        public let resourceStatusReason: String?
        /// Type of resource. For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide.
        public let resourceType: String
        /// Unique identifier of the stack.
        public let stackId: String?
        /// The name associated with the stack.
        public let stackName: String?

        public init(description: String? = nil, driftInformation: StackResourceDriftInformation? = nil, lastUpdatedTimestamp: Date, logicalResourceId: String, metadata: String? = nil, moduleInfo: ModuleInfo? = nil, physicalResourceId: String? = nil, resourceStatus: ResourceStatus, resourceStatusReason: String? = nil, resourceType: String, stackId: String? = nil, stackName: String? = nil) {
            self.description = description
            self.driftInformation = driftInformation
            self.lastUpdatedTimestamp = lastUpdatedTimestamp
            self.logicalResourceId = logicalResourceId
            self.metadata = metadata
            self.moduleInfo = moduleInfo
            self.physicalResourceId = physicalResourceId
            self.resourceStatus = resourceStatus
            self.resourceStatusReason = resourceStatusReason
            self.resourceType = resourceType
            self.stackId = stackId
            self.stackName = stackName
        }

        private enum CodingKeys: String, CodingKey {
            case description = "Description"
            case driftInformation = "DriftInformation"
            case lastUpdatedTimestamp = "LastUpdatedTimestamp"
            case logicalResourceId = "LogicalResourceId"
            case metadata = "Metadata"
            case moduleInfo = "ModuleInfo"
            case physicalResourceId = "PhysicalResourceId"
            case resourceStatus = "ResourceStatus"
            case resourceStatusReason = "ResourceStatusReason"
            case resourceType = "ResourceType"
            case stackId = "StackId"
            case stackName = "StackName"
        }
    }

    public struct StackResourceDrift: AWSDecodableShape {
        /// A JSON structure containing the actual property values of the stack resource. For resources whose StackResourceDriftStatus is DELETED, this structure will not be present.
        public let actualProperties: String?
        /// A JSON structure containing the expected property values of the stack resource, as defined in the stack template and any values specified as template parameters. For resources whose StackResourceDriftStatus is DELETED, this structure will not be present.
        public let expectedProperties: String?
        /// The logical name of the resource specified in the template.
        public let logicalResourceId: String
        /// Contains information about the module from which the resource was created, if the resource was created from a module included in the stack template.
        public let moduleInfo: ModuleInfo?
        /// The name or unique identifier that corresponds to a physical instance ID of a resource supported by CloudFormation.
        public let physicalResourceId: String?
        /// Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that resource. Each context key-value pair specifies a unique resource that contains the targeted resource.
        @OptionalCustomCoding<StandardArrayCoder>
        public var physicalResourceIdContext: [PhysicalResourceIdContextKeyValuePair]?
        /// A collection of the resource properties whose actual values differ from their expected values. These will be present only for resources whose StackResourceDriftStatus is MODIFIED.
        @OptionalCustomCoding<StandardArrayCoder>
        public var propertyDifferences: [PropertyDifference]?
        /// The type of the resource.
        public let resourceType: String
        /// The ID of the stack.
        public let stackId: String
        /// Status of the resource's actual configuration compared to its expected configuration.    DELETED: The resource differs from its expected template configuration because the resource has been deleted.    MODIFIED: One or more resource properties differ from their expected values (as defined in the stack template and any values specified as template parameters).    IN_SYNC: The resource's actual configuration matches its expected template configuration.    NOT_CHECKED: CloudFormation does not currently return this value.
        public let stackResourceDriftStatus: StackResourceDriftStatus
        /// Time at which CloudFormation performed drift detection on the stack resource.
        public let timestamp: Date

        public init(actualProperties: String? = nil, expectedProperties: String? = nil, logicalResourceId: String, moduleInfo: ModuleInfo? = nil, physicalResourceId: String? = nil, physicalResourceIdContext: [PhysicalResourceIdContextKeyValuePair]? = nil, propertyDifferences: [PropertyDifference]? = nil, resourceType: String, stackId: String, stackResourceDriftStatus: StackResourceDriftStatus, timestamp: Date) {
            self.actualProperties = actualProperties
            self.expectedProperties = expectedProperties
            self.logicalResourceId = logicalResourceId
            self.moduleInfo = moduleInfo
            self.physicalResourceId = physicalResourceId
            self.physicalResourceIdContext = physicalResourceIdContext
            self.propertyDifferences = propertyDifferences
            self.resourceType = resourceType
            self.stackId = stackId
            self.stackResourceDriftStatus = stackResourceDriftStatus
            self.timestamp = timestamp
        }

        private enum CodingKeys: String, CodingKey {
            case actualProperties = "ActualProperties"
            case expectedProperties = "ExpectedProperties"
            case logicalResourceId = "LogicalResourceId"
            case moduleInfo = "ModuleInfo"
            case physicalResourceId = "PhysicalResourceId"
            case physicalResourceIdContext = "PhysicalResourceIdContext"
            case propertyDifferences = "PropertyDifferences"
            case resourceType = "ResourceType"
            case stackId = "StackId"
            case stackResourceDriftStatus = "StackResourceDriftStatus"
            case timestamp = "Timestamp"
        }
    }

    public struct StackResourceDriftInformation: AWSDecodableShape {
        /// When CloudFormation last checked if the resource had drifted from its expected configuration.
        public let lastCheckTimestamp: Date?
        /// Status of the resource's actual configuration compared to its expected configuration    DELETED: The resource differs from its expected configuration in that it has been deleted.    MODIFIED: The resource differs from its expected configuration.    NOT_CHECKED: CloudFormation has not checked if the resource differs from its expected configuration. Any resources that do not currently support drift detection have a status of NOT_CHECKED. For more information, see Resources that Support Drift Detection.    IN_SYNC: The resource's actual configuration matches its expected configuration.
        public let stackResourceDriftStatus: StackResourceDriftStatus

        public init(lastCheckTimestamp: Date? = nil, stackResourceDriftStatus: StackResourceDriftStatus) {
            self.lastCheckTimestamp = lastCheckTimestamp
            self.stackResourceDriftStatus = stackResourceDriftStatus
        }

        private enum CodingKeys: String, CodingKey {
            case lastCheckTimestamp = "LastCheckTimestamp"
            case stackResourceDriftStatus = "StackResourceDriftStatus"
        }
    }

    public struct StackResourceDriftInformationSummary: AWSDecodableShape {
        /// When CloudFormation last checked if the resource had drifted from its expected configuration.
        public let lastCheckTimestamp: Date?
        /// Status of the resource's actual configuration compared to its expected configuration.    DELETED: The resource differs from its expected configuration in that it has been deleted.    MODIFIED: The resource differs from its expected configuration.    NOT_CHECKED: CloudFormation hasn't checked if the resource differs from its expected configuration. Any resources that don't currently support drift detection have a status of NOT_CHECKED. For more information, see Resources that Support Drift Detection. If you performed an ContinueUpdateRollback operation on a stack, any resources included in ResourcesToSkip will also have a status of NOT_CHECKED. For more information about skipping resources during rollback operations, see Continue Rolling Back an Update in the CloudFormation User Guide.    IN_SYNC: The resource's actual configuration matches its expected configuration.
        public let stackResourceDriftStatus: StackResourceDriftStatus

        public init(lastCheckTimestamp: Date? = nil, stackResourceDriftStatus: StackResourceDriftStatus) {
            self.lastCheckTimestamp = lastCheckTimestamp
            self.stackResourceDriftStatus = stackResourceDriftStatus
        }

        private enum CodingKeys: String, CodingKey {
            case lastCheckTimestamp = "LastCheckTimestamp"
            case stackResourceDriftStatus = "StackResourceDriftStatus"
        }
    }

    public struct StackResourceSummary: AWSDecodableShape {
        /// Information about whether the resource's actual configuration differs, or has drifted, from its expected configuration, as defined in the stack template and any values specified as template parameters. For more information, see Detecting Unregulated Configuration Changes to Stacks and Resources.
        public let driftInformation: StackResourceDriftInformationSummary?
        /// Time the status was updated.
        public let lastUpdatedTimestamp: Date
        /// The logical name of the resource specified in the template.
        public let logicalResourceId: String
        /// Contains information about the module from which the resource was created, if the resource was created from a module included in the stack template.
        public let moduleInfo: ModuleInfo?
        /// The name or unique identifier that corresponds to a physical instance ID of the resource.
        public let physicalResourceId: String?
        /// Current status of the resource.
        public let resourceStatus: ResourceStatus
        /// Success/failure message associated with the resource.
        public let resourceStatusReason: String?
        /// Type of resource. (For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide.)
        public let resourceType: String

        public init(driftInformation: StackResourceDriftInformationSummary? = nil, lastUpdatedTimestamp: Date, logicalResourceId: String, moduleInfo: ModuleInfo? = nil, physicalResourceId: String? = nil, resourceStatus: ResourceStatus, resourceStatusReason: String? = nil, resourceType: String) {
            self.driftInformation = driftInformation
            self.lastUpdatedTimestamp = lastUpdatedTimestamp
            self.logicalResourceId = logicalResourceId
            self.moduleInfo = moduleInfo
            self.physicalResourceId = physicalResourceId
            self.resourceStatus = resourceStatus
            self.resourceStatusReason = resourceStatusReason
            self.resourceType = resourceType
        }

        private enum CodingKeys: String, CodingKey {
            case driftInformation = "DriftInformation"
            case lastUpdatedTimestamp = "LastUpdatedTimestamp"
            case logicalResourceId = "LogicalResourceId"
            case moduleInfo = "ModuleInfo"
            case physicalResourceId = "PhysicalResourceId"
            case resourceStatus = "ResourceStatus"
            case resourceStatusReason = "ResourceStatusReason"
            case resourceType = "ResourceType"
        }
    }

    public struct StackSet: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the IAM role used to create or update the stack set. Use customized administrator roles to control which users or groups can manage specific stack sets within the same administrator account. For more information, see Prerequisites: Granting Permissions for Stack Set Operations in the CloudFormation User Guide.
        public let administrationRoleARN: String?
        /// [Service-managed permissions] Describes whether StackSets automatically deploys to Organizations accounts that are added to a target organization or organizational unit (OU).
        public let autoDeployment: AutoDeployment?
        /// The capabilities that are allowed in the stack set. Some stack set templates might include resources that can affect permissions in your Amazon Web Services account—for example, by creating new Identity and Access Management (IAM) users. For more information, see Acknowledging IAM Resources in CloudFormation Templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// A description of the stack set that you specify when the stack set is created or updated.
        public let description: String?
        /// The name of the IAM execution role used to create or update the stack set. Use customized execution roles to control which stack resources users and groups can include in their stack sets.
        public let executionRoleName: String?
        /// Describes whether StackSets performs non-conflicting operations concurrently and queues conflicting operations.
        public let managedExecution: ManagedExecution?
        /// [Service-managed permissions] The organization root ID or organizational unit (OU) IDs that you specified for DeploymentTargets.
        @OptionalCustomCoding<StandardArrayCoder>
        public var organizationalUnitIds: [String]?
        /// A list of input parameters for a stack set.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// Describes how the IAM roles required for stack set operations are created.   With self-managed permissions, you must create the administrator and execution roles required to deploy to target accounts. For more information, see Grant Self-Managed Stack Set Permissions.   With service-managed permissions, StackSets automatically creates the IAM roles required to deploy to accounts managed by Organizations. For more information, see Grant Service-Managed Stack Set Permissions.
        public let permissionModel: PermissionModels?
        /// The Amazon Resource Name (ARN) of the stack set.
        public let stackSetARN: String?
        /// Detailed information about the drift status of the stack set. For stack sets, contains information about the last completed drift operation performed on the stack set. Information about drift operations currently in progress isn't included.
        public let stackSetDriftDetectionDetails: StackSetDriftDetectionDetails?
        /// The ID of the stack set.
        public let stackSetId: String?
        /// The name that's associated with the stack set.
        public let stackSetName: String?
        /// The status of the stack set.
        public let status: StackSetStatus?
        /// A list of tags that specify information about the stack set. A maximum number of 50 tags can be specified.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// The structure that contains the body of the template that was used to create or update the stack set.
        public let templateBody: String?

        public init(administrationRoleARN: String? = nil, autoDeployment: AutoDeployment? = nil, capabilities: [Capability]? = nil, description: String? = nil, executionRoleName: String? = nil, managedExecution: ManagedExecution? = nil, organizationalUnitIds: [String]? = nil, parameters: [Parameter]? = nil, permissionModel: PermissionModels? = nil, stackSetARN: String? = nil, stackSetDriftDetectionDetails: StackSetDriftDetectionDetails? = nil, stackSetId: String? = nil, stackSetName: String? = nil, status: StackSetStatus? = nil, tags: [Tag]? = nil, templateBody: String? = nil) {
            self.administrationRoleARN = administrationRoleARN
            self.autoDeployment = autoDeployment
            self.capabilities = capabilities
            self.description = description
            self.executionRoleName = executionRoleName
            self.managedExecution = managedExecution
            self.organizationalUnitIds = organizationalUnitIds
            self.parameters = parameters
            self.permissionModel = permissionModel
            self.stackSetARN = stackSetARN
            self.stackSetDriftDetectionDetails = stackSetDriftDetectionDetails
            self.stackSetId = stackSetId
            self.stackSetName = stackSetName
            self.status = status
            self.tags = tags
            self.templateBody = templateBody
        }

        private enum CodingKeys: String, CodingKey {
            case administrationRoleARN = "AdministrationRoleARN"
            case autoDeployment = "AutoDeployment"
            case capabilities = "Capabilities"
            case description = "Description"
            case executionRoleName = "ExecutionRoleName"
            case managedExecution = "ManagedExecution"
            case organizationalUnitIds = "OrganizationalUnitIds"
            case parameters = "Parameters"
            case permissionModel = "PermissionModel"
            case stackSetARN = "StackSetARN"
            case stackSetDriftDetectionDetails = "StackSetDriftDetectionDetails"
            case stackSetId = "StackSetId"
            case stackSetName = "StackSetName"
            case status = "Status"
            case tags = "Tags"
            case templateBody = "TemplateBody"
        }
    }

    public struct StackSetDriftDetectionDetails: AWSDecodableShape {
        /// The status of the stack set drift detection operation.    COMPLETED: The drift detection operation completed without failing on any stack instances.    FAILED: The drift detection operation exceeded the specified failure tolerance.    PARTIAL_SUCCESS: The drift detection operation completed without exceeding the failure tolerance for the operation.    IN_PROGRESS: The drift detection operation is currently being performed.    STOPPED: The user has canceled the drift detection operation.
        public let driftDetectionStatus: StackSetDriftDetectionStatus?
        /// The number of stack instances that have drifted from the expected template and parameter configuration of the stack set. A stack instance is considered to have drifted if one or more of the resources in the associated stack don't match their expected configuration.
        public let driftedStackInstancesCount: Int?
        /// Status of the stack set's actual configuration compared to its expected template and parameter configuration. A stack set is considered to have drifted if one or more of its stack instances have drifted from their expected template and parameter configuration.    DRIFTED: One or more of the stack instances belonging to the stack set stack differs from the expected template and parameter configuration. A stack instance is considered to have drifted if one or more of the resources in the associated stack have drifted.    NOT_CHECKED: CloudFormation hasn't checked the stack set for drift.    IN_SYNC: All of the stack instances belonging to the stack set stack match from the expected template and parameter configuration.
        public let driftStatus: StackSetDriftStatus?
        /// The number of stack instances for which the drift detection operation failed.
        public let failedStackInstancesCount: Int?
        /// The number of stack instances that are currently being checked for drift.
        public let inProgressStackInstancesCount: Int?
        /// The number of stack instances which match the expected template and parameter configuration of the stack set.
        public let inSyncStackInstancesCount: Int?
        /// Most recent time when CloudFormation performed a drift detection operation on the stack set. This value will be NULL for any stack set on which drift detection hasn't yet been performed.
        public let lastDriftCheckTimestamp: Date?
        /// The total number of stack instances belonging to this stack set. The total number of stack instances is equal to the total of:   Stack instances that match the stack set configuration.   Stack instances that have drifted from the stack set configuration.   Stack instances where the drift detection operation has failed.   Stack instances currently being checked for drift.
        public let totalStackInstancesCount: Int?

        public init(driftDetectionStatus: StackSetDriftDetectionStatus? = nil, driftedStackInstancesCount: Int? = nil, driftStatus: StackSetDriftStatus? = nil, failedStackInstancesCount: Int? = nil, inProgressStackInstancesCount: Int? = nil, inSyncStackInstancesCount: Int? = nil, lastDriftCheckTimestamp: Date? = nil, totalStackInstancesCount: Int? = nil) {
            self.driftDetectionStatus = driftDetectionStatus
            self.driftedStackInstancesCount = driftedStackInstancesCount
            self.driftStatus = driftStatus
            self.failedStackInstancesCount = failedStackInstancesCount
            self.inProgressStackInstancesCount = inProgressStackInstancesCount
            self.inSyncStackInstancesCount = inSyncStackInstancesCount
            self.lastDriftCheckTimestamp = lastDriftCheckTimestamp
            self.totalStackInstancesCount = totalStackInstancesCount
        }

        private enum CodingKeys: String, CodingKey {
            case driftDetectionStatus = "DriftDetectionStatus"
            case driftedStackInstancesCount = "DriftedStackInstancesCount"
            case driftStatus = "DriftStatus"
            case failedStackInstancesCount = "FailedStackInstancesCount"
            case inProgressStackInstancesCount = "InProgressStackInstancesCount"
            case inSyncStackInstancesCount = "InSyncStackInstancesCount"
            case lastDriftCheckTimestamp = "LastDriftCheckTimestamp"
            case totalStackInstancesCount = "TotalStackInstancesCount"
        }
    }

    public struct StackSetOperation: AWSDecodableShape {
        /// The type of stack set operation: CREATE, UPDATE, or DELETE. Create and delete operations affect only the specified stack set instances that are associated with the specified stack set. Update operations affect both the stack set itself, in addition to all associated stack set instances.
        public let action: StackSetOperationAction?
        /// The Amazon Resource Name (ARN) of the IAM role used to perform this stack set operation. Use customized administrator roles to control which users or groups can manage specific stack sets within the same administrator account. For more information, see Define Permissions for Multiple Administrators in the CloudFormation User Guide.
        public let administrationRoleARN: String?
        /// The time at which the operation was initiated. Note that the creation times for the stack set operation might differ from the creation time of the individual stacks themselves. This is because CloudFormation needs to perform preparatory work for the operation, such as dispatching the work to the requested Regions, before actually creating the first stacks.
        public let creationTimestamp: Date?
        /// [Service-managed permissions] The Organizations accounts affected by the stack operation.
        public let deploymentTargets: DeploymentTargets?
        /// The time at which the stack set operation ended, across all accounts and Regions specified. Note that this doesn't necessarily mean that the stack set operation was successful, or even attempted, in each account or Region.
        public let endTimestamp: Date?
        /// The name of the IAM execution role used to create or update the stack set. Use customized execution roles to control which stack resources users and groups can include in their stack sets.
        public let executionRoleName: String?
        /// The unique ID of a stack set operation.
        public let operationId: String?
        /// The preferences for how CloudFormation performs this stack set operation.
        public let operationPreferences: StackSetOperationPreferences?
        /// For stack set operations of action type DELETE, specifies whether to remove the stack instances from the specified stack set, but doesn't delete the stacks. You can't re-associate a retained stack, or add an existing, saved stack to a new stack set.
        public let retainStacks: Bool?
        /// Detailed information about the drift status of the stack set. This includes information about drift operations currently being performed on the stack set. This information will only be present for stack set operations whose Action type is DETECT_DRIFT. For more information, see Detecting Unmanaged Changes in Stack Sets in the CloudFormation User Guide.
        public let stackSetDriftDetectionDetails: StackSetDriftDetectionDetails?
        /// The ID of the stack set.
        public let stackSetId: String?
        /// The status of the operation.    FAILED: The operation exceeded the specified failure tolerance. The failure tolerance value that you've set for an operation is applied for each Region during stack create and update operations. If the number of failed stacks within a Region exceeds the failure tolerance, the status of the operation in the Region is set to FAILED. This in turn sets the status of the operation as a whole to FAILED, and CloudFormation cancels the operation in any remaining Regions.    QUEUED: [Service-managed permissions] For automatic deployments that require a sequence of operations, the operation is queued to be performed. For more information, see the stack set operation status codes in the CloudFormation User Guide.    RUNNING: The operation is currently being performed.    STOPPED: The user has canceled the operation.    STOPPING: The operation is in the process of stopping, at user request.    SUCCEEDED: The operation completed creating or updating all the specified stacks without exceeding the failure tolerance for the operation.
        public let status: StackSetOperationStatus?
        /// Detailed information about the StackSet operation.
        public let statusDetails: StackSetOperationStatusDetails?
        /// The status of the operation in details.
        public let statusReason: String?

        public init(action: StackSetOperationAction? = nil, administrationRoleARN: String? = nil, creationTimestamp: Date? = nil, deploymentTargets: DeploymentTargets? = nil, endTimestamp: Date? = nil, executionRoleName: String? = nil, operationId: String? = nil, operationPreferences: StackSetOperationPreferences? = nil, retainStacks: Bool? = nil, stackSetDriftDetectionDetails: StackSetDriftDetectionDetails? = nil, stackSetId: String? = nil, status: StackSetOperationStatus? = nil, statusDetails: StackSetOperationStatusDetails? = nil, statusReason: String? = nil) {
            self.action = action
            self.administrationRoleARN = administrationRoleARN
            self.creationTimestamp = creationTimestamp
            self.deploymentTargets = deploymentTargets
            self.endTimestamp = endTimestamp
            self.executionRoleName = executionRoleName
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.retainStacks = retainStacks
            self.stackSetDriftDetectionDetails = stackSetDriftDetectionDetails
            self.stackSetId = stackSetId
            self.status = status
            self.statusDetails = statusDetails
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case action = "Action"
            case administrationRoleARN = "AdministrationRoleARN"
            case creationTimestamp = "CreationTimestamp"
            case deploymentTargets = "DeploymentTargets"
            case endTimestamp = "EndTimestamp"
            case executionRoleName = "ExecutionRoleName"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case retainStacks = "RetainStacks"
            case stackSetDriftDetectionDetails = "StackSetDriftDetectionDetails"
            case stackSetId = "StackSetId"
            case status = "Status"
            case statusDetails = "StatusDetails"
            case statusReason = "StatusReason"
        }
    }

    public struct StackSetOperationPreferences: AWSEncodableShape & AWSDecodableShape {
        /// The number of accounts, per Region, for which this operation can fail before CloudFormation stops the operation in that Region. If the operation is stopped in a Region, CloudFormation doesn't attempt the operation in any subsequent Regions. Conditional: You must specify either FailureToleranceCount or FailureTolerancePercentage (but not both). By default, 0 is specified.
        public let failureToleranceCount: Int?
        /// The percentage of accounts, per Region, for which this stack operation can fail before CloudFormation stops the operation in that Region. If the operation is stopped in a Region, CloudFormation doesn't attempt the operation in any subsequent Regions. When calculating the number of accounts based on the specified percentage, CloudFormation rounds down to the next whole number. Conditional: You must specify either FailureToleranceCount or FailureTolerancePercentage, but not both. By default, 0 is specified.
        public let failureTolerancePercentage: Int?
        /// The maximum number of accounts in which to perform this operation at one time. This is dependent on the value of FailureToleranceCount.MaxConcurrentCount is at most one more than the FailureToleranceCount. Note that this setting lets you specify the maximum for operations. For large deployments, under certain circumstances the actual number of accounts acted upon concurrently may be lower due to service throttling. Conditional: You must specify either MaxConcurrentCount or MaxConcurrentPercentage, but not both. By default, 1 is specified.
        public let maxConcurrentCount: Int?
        /// The maximum percentage of accounts in which to perform this operation at one time. When calculating the number of accounts based on the specified percentage, CloudFormation rounds down to the next whole number. This is true except in cases where rounding down would result is zero. In this case, CloudFormation sets the number as one instead. Note that this setting lets you specify the maximum for operations. For large deployments, under certain circumstances the actual number of accounts acted upon concurrently may be lower due to service throttling. Conditional: You must specify either MaxConcurrentCount or MaxConcurrentPercentage, but not both. By default, 1 is specified.
        public let maxConcurrentPercentage: Int?
        /// The concurrency type of deploying StackSets operations in Regions, could be in parallel or one Region at a time.
        public let regionConcurrencyType: RegionConcurrencyType?
        /// The order of the Regions in where you want to perform the stack operation.
        @OptionalCustomCoding<StandardArrayCoder>
        public var regionOrder: [String]?

        public init(failureToleranceCount: Int? = nil, failureTolerancePercentage: Int? = nil, maxConcurrentCount: Int? = nil, maxConcurrentPercentage: Int? = nil, regionConcurrencyType: RegionConcurrencyType? = nil, regionOrder: [String]? = nil) {
            self.failureToleranceCount = failureToleranceCount
            self.failureTolerancePercentage = failureTolerancePercentage
            self.maxConcurrentCount = maxConcurrentCount
            self.maxConcurrentPercentage = maxConcurrentPercentage
            self.regionConcurrencyType = regionConcurrencyType
            self.regionOrder = regionOrder
        }

        public func validate(name: String) throws {
            try self.validate(self.failureToleranceCount, name: "failureToleranceCount", parent: name, min: 0)
            try self.validate(self.failureTolerancePercentage, name: "failureTolerancePercentage", parent: name, max: 100)
            try self.validate(self.failureTolerancePercentage, name: "failureTolerancePercentage", parent: name, min: 0)
            try self.validate(self.maxConcurrentCount, name: "maxConcurrentCount", parent: name, min: 1)
            try self.validate(self.maxConcurrentPercentage, name: "maxConcurrentPercentage", parent: name, max: 100)
            try self.validate(self.maxConcurrentPercentage, name: "maxConcurrentPercentage", parent: name, min: 1)
            try self.regionOrder?.forEach {
                try validate($0, name: "regionOrder[]", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
            }
        }

        private enum CodingKeys: String, CodingKey {
            case failureToleranceCount = "FailureToleranceCount"
            case failureTolerancePercentage = "FailureTolerancePercentage"
            case maxConcurrentCount = "MaxConcurrentCount"
            case maxConcurrentPercentage = "MaxConcurrentPercentage"
            case regionConcurrencyType = "RegionConcurrencyType"
            case regionOrder = "RegionOrder"
        }
    }

    public struct StackSetOperationResultSummary: AWSDecodableShape {
        /// [Self-managed permissions] The name of the Amazon Web Services account for this operation result.
        public let account: String?
        /// The results of the account gate function CloudFormation invokes, if present, before proceeding with stack set operations in an account.
        public let accountGateResult: AccountGateResult?
        /// [Service-managed permissions] The organization root ID or organizational unit (OU) IDs that you specified for DeploymentTargets.
        public let organizationalUnitId: String?
        /// The name of the Amazon Web Services Region for this operation result.
        public let region: String?
        /// The result status of the stack set operation for the given account in the given Region.    CANCELLED: The operation in the specified account and Region has been canceled. This is either because a user has stopped the stack set operation, or because the failure tolerance of the stack set operation has been exceeded.    FAILED: The operation in the specified account and Region failed. If the stack set operation fails in enough accounts within a Region, the failure tolerance for the stack set operation as a whole might be exceeded.    RUNNING: The operation in the specified account and Region is currently in progress.    PENDING: The operation in the specified account and Region has yet to start.    SUCCEEDED: The operation in the specified account and Region completed successfully.
        public let status: StackSetOperationResultStatus?
        /// The reason for the assigned result status.
        public let statusReason: String?

        public init(account: String? = nil, accountGateResult: AccountGateResult? = nil, organizationalUnitId: String? = nil, region: String? = nil, status: StackSetOperationResultStatus? = nil, statusReason: String? = nil) {
            self.account = account
            self.accountGateResult = accountGateResult
            self.organizationalUnitId = organizationalUnitId
            self.region = region
            self.status = status
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case account = "Account"
            case accountGateResult = "AccountGateResult"
            case organizationalUnitId = "OrganizationalUnitId"
            case region = "Region"
            case status = "Status"
            case statusReason = "StatusReason"
        }
    }

    public struct StackSetOperationStatusDetails: AWSDecodableShape {
        /// The number of stack instances for which the StackSet operation failed.
        public let failedStackInstancesCount: Int?

        public init(failedStackInstancesCount: Int? = nil) {
            self.failedStackInstancesCount = failedStackInstancesCount
        }

        private enum CodingKeys: String, CodingKey {
            case failedStackInstancesCount = "FailedStackInstancesCount"
        }
    }

    public struct StackSetOperationSummary: AWSDecodableShape {
        /// The type of operation: CREATE, UPDATE, or DELETE. Create and delete operations affect only the specified stack instances that are associated with the specified stack set. Update operations affect both the stack set itself and all associated stack set instances.
        public let action: StackSetOperationAction?
        /// The time at which the operation was initiated. Note that the creation times for the stack set operation might differ from the creation time of the individual stacks themselves. This is because CloudFormation needs to perform preparatory work for the operation, such as dispatching the work to the requested Regions, before actually creating the first stacks.
        public let creationTimestamp: Date?
        /// The time at which the stack set operation ended, across all accounts and Regions specified. Note that this doesn't necessarily mean that the stack set operation was successful, or even attempted, in each account or Region.
        public let endTimestamp: Date?
        /// The unique ID of the stack set operation.
        public let operationId: String?
        public let operationPreferences: StackSetOperationPreferences?
        /// The overall status of the operation.    FAILED: The operation exceeded the specified failure tolerance. The failure tolerance value that you've set for an operation is applied for each Region during stack create and update operations. If the number of failed stacks within a Region exceeds the failure tolerance, the status of the operation in the Region is set to FAILED. This in turn sets the status of the operation as a whole to FAILED, and CloudFormation cancels the operation in any remaining Regions.    QUEUED: [Service-managed permissions] For automatic deployments that require a sequence of operations, the operation is queued to be performed. For more information, see the stack set operation status codes in the CloudFormation User Guide.    RUNNING: The operation is currently being performed.    STOPPED: The user has canceled the operation.    STOPPING: The operation is in the process of stopping, at user request.    SUCCEEDED: The operation completed creating or updating all the specified stacks without exceeding the failure tolerance for the operation.
        public let status: StackSetOperationStatus?
        /// Detailed information about the stack set operation.
        public let statusDetails: StackSetOperationStatusDetails?
        /// The status of the operation in details.
        public let statusReason: String?

        public init(action: StackSetOperationAction? = nil, creationTimestamp: Date? = nil, endTimestamp: Date? = nil, operationId: String? = nil, operationPreferences: StackSetOperationPreferences? = nil, status: StackSetOperationStatus? = nil, statusDetails: StackSetOperationStatusDetails? = nil, statusReason: String? = nil) {
            self.action = action
            self.creationTimestamp = creationTimestamp
            self.endTimestamp = endTimestamp
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.status = status
            self.statusDetails = statusDetails
            self.statusReason = statusReason
        }

        private enum CodingKeys: String, CodingKey {
            case action = "Action"
            case creationTimestamp = "CreationTimestamp"
            case endTimestamp = "EndTimestamp"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case status = "Status"
            case statusDetails = "StatusDetails"
            case statusReason = "StatusReason"
        }
    }

    public struct StackSetSummary: AWSDecodableShape {
        /// [Service-managed permissions] Describes whether StackSets automatically deploys to Organizations accounts that are added to a target organizational unit (OU).
        public let autoDeployment: AutoDeployment?
        /// A description of the stack set that you specify when the stack set is created or updated.
        public let description: String?
        /// Status of the stack set's actual configuration compared to its expected template and parameter configuration. A stack set is considered to have drifted if one or more of its stack instances have drifted from their expected template and parameter configuration.    DRIFTED: One or more of the stack instances belonging to the stack set stack differs from the expected template and parameter configuration. A stack instance is considered to have drifted if one or more of the resources in the associated stack have drifted.    NOT_CHECKED: CloudFormation hasn't checked the stack set for drift.    IN_SYNC: All the stack instances belonging to the stack set stack match from the expected template and parameter configuration.    UNKNOWN: This value is reserved for future use.
        public let driftStatus: StackDriftStatus?
        /// Most recent time when CloudFormation performed a drift detection operation on the stack set. This value will be NULL for any stack set on which drift detection hasn't yet been performed.
        public let lastDriftCheckTimestamp: Date?
        /// Describes whether StackSets performs non-conflicting operations concurrently and queues conflicting operations.
        public let managedExecution: ManagedExecution?
        /// Describes how the IAM roles required for stack set operations are created.   With self-managed permissions, you must create the administrator and execution roles required to deploy to target accounts. For more information, see Grant Self-Managed Stack Set Permissions.   With service-managed permissions, StackSets automatically creates the IAM roles required to deploy to accounts managed by Organizations. For more information, see Grant Service-Managed Stack Set Permissions.
        public let permissionModel: PermissionModels?
        /// The ID of the stack set.
        public let stackSetId: String?
        /// The name of the stack set.
        public let stackSetName: String?
        /// The status of the stack set.
        public let status: StackSetStatus?

        public init(autoDeployment: AutoDeployment? = nil, description: String? = nil, driftStatus: StackDriftStatus? = nil, lastDriftCheckTimestamp: Date? = nil, managedExecution: ManagedExecution? = nil, permissionModel: PermissionModels? = nil, stackSetId: String? = nil, stackSetName: String? = nil, status: StackSetStatus? = nil) {
            self.autoDeployment = autoDeployment
            self.description = description
            self.driftStatus = driftStatus
            self.lastDriftCheckTimestamp = lastDriftCheckTimestamp
            self.managedExecution = managedExecution
            self.permissionModel = permissionModel
            self.stackSetId = stackSetId
            self.stackSetName = stackSetName
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case autoDeployment = "AutoDeployment"
            case description = "Description"
            case driftStatus = "DriftStatus"
            case lastDriftCheckTimestamp = "LastDriftCheckTimestamp"
            case managedExecution = "ManagedExecution"
            case permissionModel = "PermissionModel"
            case stackSetId = "StackSetId"
            case stackSetName = "StackSetName"
            case status = "Status"
        }
    }

    public struct StackSummary: AWSDecodableShape {
        /// The time the stack was created.
        public let creationTime: Date
        /// The time the stack was deleted.
        public let deletionTime: Date?
        /// Summarizes information about whether a stack's actual configuration differs, or has drifted, from it's expected configuration, as defined in the stack template and any values specified as template parameters. For more information, see Detecting Unregulated Configuration Changes to Stacks and Resources.
        public let driftInformation: StackDriftInformationSummary?
        /// The time the stack was last updated. This field will only be returned if the stack has been updated at least once.
        public let lastUpdatedTime: Date?
        /// For nested stacks--stacks created as resources for another stack--the stack ID of the direct parent of this stack. For the first level of nested stacks, the root stack is also the parent stack. For more information, see Working with Nested Stacks in the CloudFormation User Guide.
        public let parentId: String?
        /// For nested stacks--stacks created as resources for another stack--the stack ID of the top-level stack to which the nested stack ultimately belongs. For more information, see Working with Nested Stacks in the CloudFormation User Guide.
        public let rootId: String?
        /// Unique stack identifier.
        public let stackId: String?
        /// The name associated with the stack.
        public let stackName: String
        /// The current status of the stack.
        public let stackStatus: StackStatus
        /// Success/Failure message associated with the stack status.
        public let stackStatusReason: String?
        /// The template description of the template used to create the stack.
        public let templateDescription: String?

        public init(creationTime: Date, deletionTime: Date? = nil, driftInformation: StackDriftInformationSummary? = nil, lastUpdatedTime: Date? = nil, parentId: String? = nil, rootId: String? = nil, stackId: String? = nil, stackName: String, stackStatus: StackStatus, stackStatusReason: String? = nil, templateDescription: String? = nil) {
            self.creationTime = creationTime
            self.deletionTime = deletionTime
            self.driftInformation = driftInformation
            self.lastUpdatedTime = lastUpdatedTime
            self.parentId = parentId
            self.rootId = rootId
            self.stackId = stackId
            self.stackName = stackName
            self.stackStatus = stackStatus
            self.stackStatusReason = stackStatusReason
            self.templateDescription = templateDescription
        }

        private enum CodingKeys: String, CodingKey {
            case creationTime = "CreationTime"
            case deletionTime = "DeletionTime"
            case driftInformation = "DriftInformation"
            case lastUpdatedTime = "LastUpdatedTime"
            case parentId = "ParentId"
            case rootId = "RootId"
            case stackId = "StackId"
            case stackName = "StackName"
            case stackStatus = "StackStatus"
            case stackStatusReason = "StackStatusReason"
            case templateDescription = "TemplateDescription"
        }
    }

    public struct StopStackSetOperationInput: AWSEncodableShape {
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// The ID of the stack operation.
        public let operationId: String
        /// The name or unique ID of the stack set that you want to stop the operation for.
        public let stackSetName: String

        public init(callAs: CallAs? = nil, operationId: String, stackSetName: String) {
            self.callAs = callAs
            self.operationId = operationId
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
        }

        private enum CodingKeys: String, CodingKey {
            case callAs = "CallAs"
            case operationId = "OperationId"
            case stackSetName = "StackSetName"
        }
    }

    public struct StopStackSetOperationOutput: AWSDecodableShape {
        public init() {}
    }

    public struct Tag: AWSEncodableShape & AWSDecodableShape {
        ///  Required. A string used to identify this tag. You can specify a maximum of 128 characters for a tag key. Tags owned by Amazon Web Services (Amazon Web Services) have the reserved prefix: aws:.
        public let key: String
        ///  Required. A string containing the value for this tag. You can specify a maximum of 256 characters for a tag value.
        public let value: String

        public init(key: String, value: String) {
            self.key = key
            self.value = value
        }

        public func validate(name: String) throws {
            try self.validate(self.key, name: "key", parent: name, max: 128)
            try self.validate(self.key, name: "key", parent: name, min: 1)
            try self.validate(self.value, name: "value", parent: name, max: 256)
            try self.validate(self.value, name: "value", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case key = "Key"
            case value = "Value"
        }
    }

    public struct TemplateParameter: AWSDecodableShape {
        /// The default value associated with the parameter.
        public let defaultValue: String?
        /// User defined description associated with the parameter.
        public let description: String?
        /// Flag indicating whether the parameter should be displayed as plain text in logs and UIs.
        public let noEcho: Bool?
        /// The name associated with the parameter.
        public let parameterKey: String?

        public init(defaultValue: String? = nil, description: String? = nil, noEcho: Bool? = nil, parameterKey: String? = nil) {
            self.defaultValue = defaultValue
            self.description = description
            self.noEcho = noEcho
            self.parameterKey = parameterKey
        }

        private enum CodingKeys: String, CodingKey {
            case defaultValue = "DefaultValue"
            case description = "Description"
            case noEcho = "NoEcho"
            case parameterKey = "ParameterKey"
        }
    }

    public struct TestTypeInput: AWSEncodableShape {
        /// The Amazon Resource Name (ARN) of the extension. Conditional: You must specify Arn, or TypeName and Type.
        public let arn: String?
        /// The S3 bucket to which CloudFormation delivers the contract test execution logs. CloudFormation delivers the logs by the time contract testing has completed and the extension has been assigned a test type status of PASSED or FAILED. The user calling TestType must be able to access items in the specified S3 bucket. Specifically, the user needs the following permissions:    GetObject     PutObject    For more information, see Actions, Resources, and Condition Keys for Amazon S3 in the Amazon Web Services Identity and Access Management User Guide.
        public let logDeliveryBucket: String?
        /// The type of the extension to test. Conditional: You must specify Arn, or TypeName and Type.
        public let type: ThirdPartyType?
        /// The name of the extension to test. Conditional: You must specify Arn, or TypeName and Type.
        public let typeName: String?
        /// The version of the extension to test. You can specify the version id with either Arn, or with TypeName and Type. If you don't specify a version, CloudFormation uses the default version of the extension in this account and region for testing.
        public let versionId: String?

        public init(arn: String? = nil, logDeliveryBucket: String? = nil, type: ThirdPartyType? = nil, typeName: String? = nil, versionId: String? = nil) {
            self.arn = arn
            self.logDeliveryBucket = logDeliveryBucket
            self.type = type
            self.typeName = typeName
            self.versionId = versionId
        }

        public func validate(name: String) throws {
            try self.validate(self.arn, name: "arn", parent: name, max: 1024)
            try self.validate(self.arn, name: "arn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.logDeliveryBucket, name: "logDeliveryBucket", parent: name, max: 63)
            try self.validate(self.logDeliveryBucket, name: "logDeliveryBucket", parent: name, min: 3)
            try self.validate(self.logDeliveryBucket, name: "logDeliveryBucket", parent: name, pattern: "^[\\s\\S]+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
            try self.validate(self.versionId, name: "versionId", parent: name, max: 128)
            try self.validate(self.versionId, name: "versionId", parent: name, min: 1)
            try self.validate(self.versionId, name: "versionId", parent: name, pattern: "^[A-Za-z0-9-]+$")
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case logDeliveryBucket = "LogDeliveryBucket"
            case type = "Type"
            case typeName = "TypeName"
            case versionId = "VersionId"
        }
    }

    public struct TestTypeOutput: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the extension.
        public let typeVersionArn: String?

        public init(typeVersionArn: String? = nil) {
            self.typeVersionArn = typeVersionArn
        }

        private enum CodingKeys: String, CodingKey {
            case typeVersionArn = "TypeVersionArn"
        }
    }

    public struct TypeConfigurationDetails: AWSDecodableShape {
        /// The alias specified for this configuration, if one was specified when the configuration was set.
        public let alias: String?
        /// The Amazon Resource Name (ARN) for the configuration data, in this account and region.
        public let arn: String?
        /// A JSON string specifying the configuration data for the extension, in this account and region. If a configuration hasn't been set for a specified extension, CloudFormation returns {}.
        public let configuration: String?
        /// Whether this configuration data is the default configuration for the extension.
        public let isDefaultConfiguration: Bool?
        /// When the configuration data was last updated for this extension. If a configuration hasn't been set for a specified extension, CloudFormation returns null.
        public let lastUpdated: Date?
        /// The Amazon Resource Name (ARN) for the extension, in this account and region. For public extensions, this will be the ARN assigned when you activate the type in this account and region. For private extensions, this will be the ARN assigned when you register the type in this account and region.
        public let typeArn: String?
        /// The name of the extension.
        public let typeName: String?

        public init(alias: String? = nil, arn: String? = nil, configuration: String? = nil, isDefaultConfiguration: Bool? = nil, lastUpdated: Date? = nil, typeArn: String? = nil, typeName: String? = nil) {
            self.alias = alias
            self.arn = arn
            self.configuration = configuration
            self.isDefaultConfiguration = isDefaultConfiguration
            self.lastUpdated = lastUpdated
            self.typeArn = typeArn
            self.typeName = typeName
        }

        private enum CodingKeys: String, CodingKey {
            case alias = "Alias"
            case arn = "Arn"
            case configuration = "Configuration"
            case isDefaultConfiguration = "IsDefaultConfiguration"
            case lastUpdated = "LastUpdated"
            case typeArn = "TypeArn"
            case typeName = "TypeName"
        }
    }

    public struct TypeConfigurationIdentifier: AWSEncodableShape & AWSDecodableShape {
        /// The type of extension.
        public let type: ThirdPartyType?
        /// The Amazon Resource Name (ARN) for the extension, in this account and region. For public extensions, this will be the ARN assigned when you activate the type in this account and region. For private extensions, this will be the ARN assigned when you register the type in this account and region.
        public let typeArn: String?
        /// The alias specified for this configuration, if one was specified when the configuration was set.
        public let typeConfigurationAlias: String?
        /// The Amazon Resource Name (ARN) for the configuration, in this account and region.
        public let typeConfigurationArn: String?
        /// The name of the extension type to which this configuration applies.
        public let typeName: String?

        public init(type: ThirdPartyType? = nil, typeArn: String? = nil, typeConfigurationAlias: String? = nil, typeConfigurationArn: String? = nil, typeName: String? = nil) {
            self.type = type
            self.typeArn = typeArn
            self.typeConfigurationAlias = typeConfigurationAlias
            self.typeConfigurationArn = typeConfigurationArn
            self.typeName = typeName
        }

        public func validate(name: String) throws {
            try self.validate(self.typeArn, name: "typeArn", parent: name, max: 1024)
            try self.validate(self.typeArn, name: "typeArn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type/.+$")
            try self.validate(self.typeConfigurationAlias, name: "typeConfigurationAlias", parent: name, max: 256)
            try self.validate(self.typeConfigurationAlias, name: "typeConfigurationAlias", parent: name, min: 1)
            try self.validate(self.typeConfigurationAlias, name: "typeConfigurationAlias", parent: name, pattern: "^[a-zA-Z0-9]{1,256}$")
            try self.validate(self.typeConfigurationArn, name: "typeConfigurationArn", parent: name, max: 1024)
            try self.validate(self.typeConfigurationArn, name: "typeConfigurationArn", parent: name, pattern: "^arn:aws[A-Za-z0-9-]{0,64}:cloudformation:[A-Za-z0-9-]{1,64}:([0-9]{12})?:type-configuration/.+$")
            try self.validate(self.typeName, name: "typeName", parent: name, max: 204)
            try self.validate(self.typeName, name: "typeName", parent: name, min: 10)
            try self.validate(self.typeName, name: "typeName", parent: name, pattern: "^[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}::[A-Za-z0-9]{2,64}(::MODULE){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case type = "Type"
            case typeArn = "TypeArn"
            case typeConfigurationAlias = "TypeConfigurationAlias"
            case typeConfigurationArn = "TypeConfigurationArn"
            case typeName = "TypeName"
        }
    }

    public struct TypeFilters: AWSEncodableShape {
        /// The category of extensions to return.    REGISTERED: Private extensions that have been registered for this account and region.    ACTIVATED: Public extensions that have been activated for this account and region.    THIRD_PARTY: Extensions available for use from publishers other than Amazon. This includes:   Private extensions registered in the account.   Public extensions from publishers other than Amazon, whether activated or not.      AWS_TYPES: Extensions available for use from Amazon.
        public let category: Category?
        /// The id of the publisher of the extension. Extensions published by Amazon aren't assigned a publisher ID. Use the AWS_TYPES category to specify a list of types published by Amazon.
        public let publisherId: String?
        /// A prefix to use as a filter for results.
        public let typeNamePrefix: String?

        public init(category: Category? = nil, publisherId: String? = nil, typeNamePrefix: String? = nil) {
            self.category = category
            self.publisherId = publisherId
            self.typeNamePrefix = typeNamePrefix
        }

        public func validate(name: String) throws {
            try self.validate(self.publisherId, name: "publisherId", parent: name, max: 40)
            try self.validate(self.publisherId, name: "publisherId", parent: name, min: 1)
            try self.validate(self.publisherId, name: "publisherId", parent: name, pattern: "^[0-9a-zA-Z]{12,40}$")
            try self.validate(self.typeNamePrefix, name: "typeNamePrefix", parent: name, max: 204)
            try self.validate(self.typeNamePrefix, name: "typeNamePrefix", parent: name, min: 1)
            try self.validate(self.typeNamePrefix, name: "typeNamePrefix", parent: name, pattern: "^([A-Za-z0-9]{2,64}::){0,2}([A-Za-z0-9]{2,64}:?){0,1}$")
        }

        private enum CodingKeys: String, CodingKey {
            case category = "Category"
            case publisherId = "PublisherId"
            case typeNamePrefix = "TypeNamePrefix"
        }
    }

    public struct TypeSummary: AWSDecodableShape {
        /// The ID of the default version of the extension. The default version is used when the extension version isn't specified. This applies only to private extensions you have registered in your account. For public extensions, both those provided by Amazon and published by third parties, CloudFormation returns null. For more information, see RegisterType. To set the default version of an extension, use  SetTypeDefaultVersion .
        public let defaultVersionId: String?
        /// The description of the extension.
        public let description: String?
        /// Whether the extension is activated for this account and region. This applies only to third-party public extensions. Extensions published by Amazon are activated by default.
        public let isActivated: Bool?
        /// When the specified extension version was registered. This applies only to:   Private extensions you have registered in your account. For more information, see RegisterType.   Public extensions you have activated in your account with auto-update specified. For more information, see ActivateType.   For all other extension types, CloudFormation returns null.
        public let lastUpdated: Date?
        /// For public extensions that have been activated for this account and region, the latest version of the public extension that is available. For any extensions other than activated third-arty extensions, CloudFormation returns null. How you specified AutoUpdate when enabling the extension affects whether CloudFormation automatically updates the extension in this account and region when a new version is released. For more information, see Setting CloudFormation to automatically use new versions of extensions in the CloudFormation User Guide.
        public let latestPublicVersion: String?
        /// For public extensions that have been activated for this account and region, the type name of the public extension. If you specified a TypeNameAlias when enabling the extension in this account and region, CloudFormation treats that alias as the extension's type name within the account and region, not the type name of the public extension. For more information, see Specifying aliases to refer to extensions in the CloudFormation User Guide.
        public let originalTypeName: String?
        /// For public extensions that have been activated for this account and region, the version of the public extension to be used for CloudFormation operations in this account and Region. How you specified AutoUpdate when enabling the extension affects whether CloudFormation automatically updates the extension in this account and region when a new version is released. For more information, see Setting CloudFormation to automatically use new versions of extensions in the CloudFormation User Guide.
        public let publicVersionNumber: String?
        /// The ID of the extension publisher, if the extension is published by a third party. Extensions published by Amazon don't return a publisher ID.
        public let publisherId: String?
        /// The service used to verify the publisher identity. For more information, see Registering your account to publish CloudFormation extensions in the CFN-CLI User Guide for Extension Development.
        public let publisherIdentity: IdentityProvider?
        /// The publisher name, as defined in the public profile for that publisher in the service used to verify the publisher identity.
        public let publisherName: String?
        /// The kind of extension.
        public let type: RegistryType?
        /// The Amazon Resource Name (ARN) of the extension.
        public let typeArn: String?
        /// The name of the extension. If you specified a TypeNameAlias when you activate this extension in your account and region, CloudFormation considers that alias as the type name.
        public let typeName: String?

        public init(defaultVersionId: String? = nil, description: String? = nil, isActivated: Bool? = nil, lastUpdated: Date? = nil, latestPublicVersion: String? = nil, originalTypeName: String? = nil, publicVersionNumber: String? = nil, publisherId: String? = nil, publisherIdentity: IdentityProvider? = nil, publisherName: String? = nil, type: RegistryType? = nil, typeArn: String? = nil, typeName: String? = nil) {
            self.defaultVersionId = defaultVersionId
            self.description = description
            self.isActivated = isActivated
            self.lastUpdated = lastUpdated
            self.latestPublicVersion = latestPublicVersion
            self.originalTypeName = originalTypeName
            self.publicVersionNumber = publicVersionNumber
            self.publisherId = publisherId
            self.publisherIdentity = publisherIdentity
            self.publisherName = publisherName
            self.type = type
            self.typeArn = typeArn
            self.typeName = typeName
        }

        private enum CodingKeys: String, CodingKey {
            case defaultVersionId = "DefaultVersionId"
            case description = "Description"
            case isActivated = "IsActivated"
            case lastUpdated = "LastUpdated"
            case latestPublicVersion = "LatestPublicVersion"
            case originalTypeName = "OriginalTypeName"
            case publicVersionNumber = "PublicVersionNumber"
            case publisherId = "PublisherId"
            case publisherIdentity = "PublisherIdentity"
            case publisherName = "PublisherName"
            case type = "Type"
            case typeArn = "TypeArn"
            case typeName = "TypeName"
        }
    }

    public struct TypeVersionSummary: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the extension version.
        public let arn: String?
        /// The description of the extension version.
        public let description: String?
        /// Whether the specified extension version is set as the default version. This applies only to private extensions you have registered in your account, and extensions published by Amazon. For public third-party extensions, CloudFormation returns null.
        public let isDefaultVersion: Bool?
        /// For public extensions that have been activated for this account and region, the version of the public extension to be used for CloudFormation operations in this account and region. For any extensions other than activated third-arty extensions, CloudFormation returns null. How you specified AutoUpdate when enabling the extension affects whether CloudFormation automatically updates the extension in this account and region when a new version is released. For more information, see Setting CloudFormation to automatically use new versions of extensions in the CloudFormation User Guide.
        public let publicVersionNumber: String?
        /// When the version was registered.
        public let timeCreated: Date?
        /// The kind of extension.
        public let type: RegistryType?
        /// The name of the extension.
        public let typeName: String?
        /// The ID of a specific version of the extension. The version ID is the value at the end of the Amazon Resource Name (ARN) assigned to the extension version when it's registered.
        public let versionId: String?

        public init(arn: String? = nil, description: String? = nil, isDefaultVersion: Bool? = nil, publicVersionNumber: String? = nil, timeCreated: Date? = nil, type: RegistryType? = nil, typeName: String? = nil, versionId: String? = nil) {
            self.arn = arn
            self.description = description
            self.isDefaultVersion = isDefaultVersion
            self.publicVersionNumber = publicVersionNumber
            self.timeCreated = timeCreated
            self.type = type
            self.typeName = typeName
            self.versionId = versionId
        }

        private enum CodingKeys: String, CodingKey {
            case arn = "Arn"
            case description = "Description"
            case isDefaultVersion = "IsDefaultVersion"
            case publicVersionNumber = "PublicVersionNumber"
            case timeCreated = "TimeCreated"
            case type = "Type"
            case typeName = "TypeName"
            case versionId = "VersionId"
        }
    }

    public struct UpdateStackInput: AWSEncodableShape {
        /// In some cases, you must explicitly acknowledge that your stack template contains certain capabilities in order for CloudFormation to update the stack.    CAPABILITY_IAM and CAPABILITY_NAMED_IAM  Some stack templates might include resources that can affect permissions in your Amazon Web Services account; for example, by creating new Identity and Access Management (IAM) users. For those stacks, you must explicitly acknowledge this by specifying one of these capabilities. The following IAM resources require you to specify either the CAPABILITY_IAM or CAPABILITY_NAMED_IAM capability.   If you have IAM resources, you can specify either capability.   If you have IAM resources with custom names, you must specify CAPABILITY_NAMED_IAM.   If you don't specify either of these capabilities, CloudFormation returns an InsufficientCapabilities error.   If your stack template contains these resources, we suggest that you review all permissions associated with them and edit their permissions if necessary.     AWS::IAM::AccessKey      AWS::IAM::Group     AWS::IAM::InstanceProfile      AWS::IAM::Policy      AWS::IAM::Role      AWS::IAM::User     AWS::IAM::UserToGroupAddition    For more information, see Acknowledging IAM Resources in CloudFormation Templates.    CAPABILITY_AUTO_EXPAND  Some template contain macros. Macros perform custom processing on templates; this can include simple actions like find-and-replace operations, all the way to extensive transformations of entire templates. Because of this, users typically create a change set from the processed template, so that they can review the changes resulting from the macros before actually updating the stack. If your stack template contains one or more macros, and you choose to update a stack directly from the processed template, without first reviewing the resulting changes in a change set, you must acknowledge this capability. This includes the AWS::Include and AWS::Serverless transforms, which are macros hosted by CloudFormation. If you want to update a stack from a stack template that contains macros and nested stacks, you must update the stack directly from the template using this capability.  You should only update stacks directly from a stack template that contains macros if you know what processing the macro performs. Each macro relies on an underlying Lambda service function for processing stack templates. Be aware that the Lambda function owner can update the function operation without CloudFormation being notified.  For more information, see Using CloudFormation Macros to Perform Custom Processing on Templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// A unique identifier for this UpdateStack request. Specify this token if you plan to retry requests so that CloudFormation knows that you're not attempting to update a stack with the same name. You might retry UpdateStack requests to ensure that CloudFormation successfully received them. All events triggered by a given stack operation are assigned the same client request token, which you can use to track operations. For example, if you execute a CreateStack operation with the token token1, then all the StackEvents generated by that operation will have ClientRequestToken set as token1. In the console, stack operations display the client request token on the Events tab. Stack operations that are initiated from the console use the token format Console-StackOperation-ID, which helps you easily identify the stack operation . For example, if you create a stack using the console, each stack event would be assigned the same token in the following format: Console-CreateStack-7f59c3cf-00d2-40c7-b2ff-e75db0987002.
        public let clientRequestToken: String?
        /// Preserve the state of previously provisioned resources when an operation fails. Default: False
        public let disableRollback: Bool?
        /// Amazon Simple Notification Service topic Amazon Resource Names (ARNs) that CloudFormation associates with the stack. Specify an empty list to remove all notification topics.
        @OptionalCustomCoding<StandardArrayCoder>
        public var notificationARNs: [String]?
        /// A list of Parameter structures that specify input parameters for the stack. For more information, see the Parameter data type.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// The template resource types that you have permissions to work with for this update stack action, such as AWS::EC2::Instance, AWS::EC2::*, or Custom::MyCustomInstance. If the list of resource types doesn't include a resource that you're updating, the stack update fails. By default, CloudFormation grants permissions to all resource types. Identity and Access Management (IAM) uses this parameter for CloudFormation-specific condition keys in IAM policies. For more information, see Controlling Access with Identity and Access Management.
        @OptionalCustomCoding<StandardArrayCoder>
        public var resourceTypes: [String]?
        /// The Amazon Resource Name (ARN) of an Identity and Access Management (IAM) role that CloudFormation assumes to update the stack. CloudFormation uses the role's credentials to make calls on your behalf. CloudFormation always uses this role for all future operations on the stack. Provided that users have permission to operate on the stack, CloudFormation uses this role even if the users don't have permission to pass it. Ensure that the role grants least privilege. If you don't specify a value, CloudFormation uses the role that was previously associated with the stack. If no role is available, CloudFormation uses a temporary session that is generated from your user credentials.
        public let roleARN: String?
        /// The rollback triggers for CloudFormation to monitor during stack creation and updating operations, and for the specified monitoring period afterwards.
        public let rollbackConfiguration: RollbackConfiguration?
        /// The name or unique stack ID of the stack to update.
        public let stackName: String
        /// Structure containing a new stack policy body. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both. You might update the stack policy, for example, in order to protect a new resource that you created during a stack update. If you don't specify a stack policy, the current policy that is associated with the stack is unchanged.
        public let stackPolicyBody: String?
        /// Structure containing the temporary overriding stack policy body. You can specify either the StackPolicyDuringUpdateBody or the StackPolicyDuringUpdateURL parameter, but not both. If you want to update protected resources, specify a temporary overriding stack policy during this update. If you don't specify a stack policy, the current policy that is associated with the stack will be used.
        public let stackPolicyDuringUpdateBody: String?
        /// Location of a file containing the temporary overriding stack policy. The URL must point to a policy (max size: 16KB) located in an S3 bucket in the same Region as the stack. You can specify either the StackPolicyDuringUpdateBody or the StackPolicyDuringUpdateURL parameter, but not both. If you want to update protected resources, specify a temporary overriding stack policy during this update. If you don't specify a stack policy, the current policy that is associated with the stack will be used.
        public let stackPolicyDuringUpdateURL: String?
        /// Location of a file containing the updated stack policy. The URL must point to a policy (max size: 16KB) located in an S3 bucket in the same Region as the stack. You can specify either the StackPolicyBody or the StackPolicyURL parameter, but not both. You might update the stack policy, for example, in order to protect a new resource that you created during a stack update. If you don't specify a stack policy, the current policy that is associated with the stack is unchanged.
        public let stackPolicyURL: String?
        /// Key-value pairs to associate with this stack. CloudFormation also propagates these tags to supported resources in the stack. You can specify a maximum number of 50 tags. If you don't specify this parameter, CloudFormation doesn't modify the stack's tags. If you specify an empty value, CloudFormation removes all associated tags.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. (For more information, go to Template Anatomy in the CloudFormation User Guide.) Conditional: You must specify only one of the following parameters: TemplateBody, TemplateURL, or set the UsePreviousTemplate to true.
        public let templateBody: String?
        /// Location of file containing the template body. The URL must point to a template that's located in an Amazon S3 bucket or a Systems Manager document. For more information, go to Template Anatomy in the CloudFormation User Guide. Conditional: You must specify only one of the following parameters: TemplateBody, TemplateURL, or set the UsePreviousTemplate to true.
        public let templateURL: String?
        /// Reuse the existing template that is associated with the stack that you are updating. Conditional: You must specify only one of the following parameters: TemplateBody, TemplateURL, or set the UsePreviousTemplate to true.
        public let usePreviousTemplate: Bool?

        public init(capabilities: [Capability]? = nil, clientRequestToken: String? = nil, disableRollback: Bool? = nil, notificationARNs: [String]? = nil, parameters: [Parameter]? = nil, resourceTypes: [String]? = nil, roleARN: String? = nil, rollbackConfiguration: RollbackConfiguration? = nil, stackName: String, stackPolicyBody: String? = nil, stackPolicyDuringUpdateBody: String? = nil, stackPolicyDuringUpdateURL: String? = nil, stackPolicyURL: String? = nil, tags: [Tag]? = nil, templateBody: String? = nil, templateURL: String? = nil, usePreviousTemplate: Bool? = nil) {
            self.capabilities = capabilities
            self.clientRequestToken = clientRequestToken
            self.disableRollback = disableRollback
            self.notificationARNs = notificationARNs
            self.parameters = parameters
            self.resourceTypes = resourceTypes
            self.roleARN = roleARN
            self.rollbackConfiguration = rollbackConfiguration
            self.stackName = stackName
            self.stackPolicyBody = stackPolicyBody
            self.stackPolicyDuringUpdateBody = stackPolicyDuringUpdateBody
            self.stackPolicyDuringUpdateURL = stackPolicyDuringUpdateURL
            self.stackPolicyURL = stackPolicyURL
            self.tags = tags
            self.templateBody = templateBody
            self.templateURL = templateURL
            self.usePreviousTemplate = usePreviousTemplate
        }

        public func validate(name: String) throws {
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, max: 128)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, min: 1)
            try self.validate(self.clientRequestToken, name: "clientRequestToken", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.validate(self.notificationARNs, name: "notificationARNs", parent: name, max: 5)
            try self.resourceTypes?.forEach {
                try validate($0, name: "resourceTypes[]", parent: name, max: 256)
                try validate($0, name: "resourceTypes[]", parent: name, min: 1)
            }
            try self.validate(self.roleARN, name: "roleARN", parent: name, max: 2048)
            try self.validate(self.roleARN, name: "roleARN", parent: name, min: 20)
            try self.rollbackConfiguration?.validate(name: "\(name).rollbackConfiguration")
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, max: 16384)
            try self.validate(self.stackPolicyBody, name: "stackPolicyBody", parent: name, min: 1)
            try self.validate(self.stackPolicyDuringUpdateBody, name: "stackPolicyDuringUpdateBody", parent: name, max: 16384)
            try self.validate(self.stackPolicyDuringUpdateBody, name: "stackPolicyDuringUpdateBody", parent: name, min: 1)
            try self.validate(self.stackPolicyDuringUpdateURL, name: "stackPolicyDuringUpdateURL", parent: name, max: 1350)
            try self.validate(self.stackPolicyDuringUpdateURL, name: "stackPolicyDuringUpdateURL", parent: name, min: 1)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, max: 1350)
            try self.validate(self.stackPolicyURL, name: "stackPolicyURL", parent: name, min: 1)
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case clientRequestToken = "ClientRequestToken"
            case disableRollback = "DisableRollback"
            case notificationARNs = "NotificationARNs"
            case parameters = "Parameters"
            case resourceTypes = "ResourceTypes"
            case roleARN = "RoleARN"
            case rollbackConfiguration = "RollbackConfiguration"
            case stackName = "StackName"
            case stackPolicyBody = "StackPolicyBody"
            case stackPolicyDuringUpdateBody = "StackPolicyDuringUpdateBody"
            case stackPolicyDuringUpdateURL = "StackPolicyDuringUpdateURL"
            case stackPolicyURL = "StackPolicyURL"
            case tags = "Tags"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
            case usePreviousTemplate = "UsePreviousTemplate"
        }
    }

    public struct UpdateStackInstancesInput: AWSEncodableShape {
        /// [Self-managed permissions] The names of one or more Amazon Web Services accounts for which you want to update parameter values for stack instances. The overridden parameter values will be applied to all stack instances in the specified accounts and Amazon Web Services Regions. You can specify Accounts or DeploymentTargets, but not both.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accounts: [String]?
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// [Service-managed permissions] The Organizations accounts for which you want to update parameter values for stack instances. If your update targets OUs, the overridden parameter values only apply to the accounts that are currently in the target OUs and their child OUs. Accounts added to the target OUs and their child OUs in the future won't use the overridden values. You can specify Accounts or DeploymentTargets, but not both.
        public let deploymentTargets: DeploymentTargets?
        /// The unique identifier for this stack set operation. The operation ID also functions as an idempotency token, to ensure that CloudFormation performs the stack set operation only once, even if you retry the request multiple times. You might retry stack set operation requests to ensure that CloudFormation successfully received them. If you don't specify an operation ID, the SDK generates one automatically.
        public let operationId: String?
        /// Preferences for how CloudFormation performs this stack set operation.
        public let operationPreferences: StackSetOperationPreferences?
        /// A list of input parameters whose values you want to update for the specified stack instances. Any overridden parameter values will be applied to all stack instances in the specified accounts and Amazon Web Services Regions. When specifying parameters and their values, be aware of how CloudFormation sets parameter values during stack instance update operations:   To override the current value for a parameter, include the parameter and specify its value.   To leave an overridden parameter set to its present value, include the parameter and specify UsePreviousValue as true. (You can't specify both a value and set UsePreviousValue to true.)   To set an overridden parameter back to the value specified in the stack set, specify a parameter list but don't include the parameter in the list.   To leave all parameters set to their present values, don't specify this property at all.   During stack set updates, any parameter values overridden for a stack instance aren't updated, but retain their overridden value. You can only override the parameter values that are specified in the stack set; to add or delete a parameter itself, use UpdateStackSet to update the stack set template. If you add a parameter to a template, before you can override the parameter value specified in the stack set you must first use UpdateStackSet to update all stack instances with the updated template and parameter value specified in the stack set. Once a stack instance has been updated with the new parameter, you can then override the parameter value using UpdateStackInstances.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameterOverrides: [Parameter]?
        /// The names of one or more Amazon Web Services Regions in which you want to update parameter values for stack instances. The overridden parameter values will be applied to all stack instances in the specified accounts and Amazon Web Services Regions.
        @CustomCoding<StandardArrayCoder>
        public var regions: [String]
        /// The name or unique ID of the stack set associated with the stack instances.
        public let stackSetName: String

        public init(accounts: [String]? = nil, callAs: CallAs? = nil, deploymentTargets: DeploymentTargets? = nil, operationId: String? = UpdateStackInstancesInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, parameterOverrides: [Parameter]? = nil, regions: [String], stackSetName: String) {
            self.accounts = accounts
            self.callAs = callAs
            self.deploymentTargets = deploymentTargets
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.parameterOverrides = parameterOverrides
            self.regions = regions
            self.stackSetName = stackSetName
        }

        public func validate(name: String) throws {
            try self.accounts?.forEach {
                try validate($0, name: "accounts[]", parent: name, pattern: "^[0-9]{12}$")
            }
            try self.deploymentTargets?.validate(name: "\(name).deploymentTargets")
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.regions.forEach {
                try validate($0, name: "regions[]", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
            }
            try self.validate(self.stackSetName, name: "stackSetName", parent: name, pattern: "^[a-zA-Z][-a-zA-Z0-9]*(?::[a-zA-Z0-9]{8}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{4}-[a-zA-Z0-9]{12})?$")
        }

        private enum CodingKeys: String, CodingKey {
            case accounts = "Accounts"
            case callAs = "CallAs"
            case deploymentTargets = "DeploymentTargets"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case parameterOverrides = "ParameterOverrides"
            case regions = "Regions"
            case stackSetName = "StackSetName"
        }
    }

    public struct UpdateStackInstancesOutput: AWSDecodableShape {
        /// The unique identifier for this stack set operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct UpdateStackOutput: AWSDecodableShape {
        /// Unique identifier of the stack.
        public let stackId: String?

        public init(stackId: String? = nil) {
            self.stackId = stackId
        }

        private enum CodingKeys: String, CodingKey {
            case stackId = "StackId"
        }
    }

    public struct UpdateStackSetInput: AWSEncodableShape {
        /// [Self-managed permissions] The accounts in which to update associated stack instances. If you specify accounts, you must also specify the Amazon Web Services Regions in which to update stack set instances. To update all the stack instances associated with this stack set, don't specify the Accounts or Regions properties. If the stack set update includes changes to the template (that is, if the TemplateBody or TemplateURL properties are specified), or the Parameters property, CloudFormation marks all stack instances with a status of OUTDATED prior to updating the stack instances in the specified accounts and Amazon Web Services Regions. If the stack set update does not include changes to the template or parameters, CloudFormation updates the stack instances in the specified accounts and Amazon Web Services Regions, while leaving all other stack instances with their existing stack instance status.
        @OptionalCustomCoding<StandardArrayCoder>
        public var accounts: [String]?
        /// The Amazon Resource Name (ARN) of the IAM role to use to update this stack set. Specify an IAM role only if you are using customized administrator roles to control which users or groups can manage specific stack sets within the same administrator account. For more information, see Granting Permissions for Stack Set Operations in the CloudFormation User Guide. If you specified a customized administrator role when you created the stack set, you must specify a customized administrator role, even if it is the same customized administrator role used with this stack set previously.
        public let administrationRoleARN: String?
        /// [Service-managed permissions] Describes whether StackSets automatically deploys to Organizations accounts that are added to a target organization or organizational unit (OU). If you specify AutoDeployment, don't specify DeploymentTargets or Regions.
        public let autoDeployment: AutoDeployment?
        /// [Service-managed permissions] Specifies whether you are acting as an account administrator in the organization's management account or as a delegated administrator in a member account. By default, SELF is specified. Use SELF for stack sets with self-managed permissions.   If you are signed in to the management account, specify SELF.   If you are signed in to a delegated administrator account, specify DELEGATED_ADMIN. Your Amazon Web Services account must be registered as a delegated administrator in the management account. For more information, see Register a delegated administrator in the CloudFormation User Guide.
        public let callAs: CallAs?
        /// In some cases, you must explicitly acknowledge that your stack template contains certain capabilities in order for CloudFormation to update the stack set and its associated stack instances.    CAPABILITY_IAM and CAPABILITY_NAMED_IAM  Some stack templates might include resources that can affect permissions in your Amazon Web Services account; for example, by creating new Identity and Access Management (IAM) users. For those stacks sets, you must explicitly acknowledge this by specifying one of these capabilities. The following IAM resources require you to specify either the CAPABILITY_IAM or CAPABILITY_NAMED_IAM capability.   If you have IAM resources, you can specify either capability.   If you have IAM resources with custom names, you must specify CAPABILITY_NAMED_IAM.   If you don't specify either of these capabilities, CloudFormation returns an InsufficientCapabilities error.   If your stack template contains these resources, we recommend that you review all permissions associated with them and edit their permissions if necessary.     AWS::IAM::AccessKey      AWS::IAM::Group     AWS::IAM::InstanceProfile      AWS::IAM::Policy      AWS::IAM::Role      AWS::IAM::User     AWS::IAM::UserToGroupAddition    For more information, see Acknowledging IAM Resources in CloudFormation Templates.    CAPABILITY_AUTO_EXPAND  Some templates reference macros. If your stack set template references one or more macros, you must update the stack set directly from the processed template, without first reviewing the resulting changes in a change set. To update the stack set directly, you must acknowledge this capability. For more information, see Using CloudFormation Macros to Perform Custom Processing on Templates.  Stack sets with service-managed permissions do not currently support the use of macros in templates. (This includes the AWS::Include and AWS::Serverless transforms, which are macros hosted by CloudFormation.) Even if you specify this capability for a stack set with service-managed permissions, if you reference a macro in your template the stack set operation will fail.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// [Service-managed permissions] The Organizations accounts in which to update associated stack instances. To update all the stack instances associated with this stack set, do not specify DeploymentTargets or Regions. If the stack set update includes changes to the template (that is, if TemplateBody or TemplateURL is specified), or the Parameters, CloudFormation marks all stack instances with a status of OUTDATED prior to updating the stack instances in the specified accounts and Amazon Web Services Regions. If the stack set update doesn't include changes to the template or parameters, CloudFormation updates the stack instances in the specified accounts and Regions, while leaving all other stack instances with their existing stack instance status.
        public let deploymentTargets: DeploymentTargets?
        /// A brief description of updates that you are making.
        public let description: String?
        /// The name of the IAM execution role to use to update the stack set. If you do not specify an execution role, CloudFormation uses the AWSCloudFormationStackSetExecutionRole role for the stack set operation. Specify an IAM role only if you are using customized execution roles to control which stack resources users and groups can include in their stack sets. If you specify a customized execution role, CloudFormation uses that role to update the stack. If you do not specify a customized execution role, CloudFormation performs the update using the role previously associated with the stack set, so long as you have permissions to perform operations on the stack set.
        public let executionRoleName: String?
        /// Describes whether StackSets performs non-conflicting operations concurrently and queues conflicting operations.
        public let managedExecution: ManagedExecution?
        /// The unique ID for this stack set operation. The operation ID also functions as an idempotency token, to ensure that CloudFormation performs the stack set operation only once, even if you retry the request multiple times. You might retry stack set operation requests to ensure that CloudFormation successfully received them. If you don't specify an operation ID, CloudFormation generates one automatically. Repeating this stack set operation with a new operation ID retries all stack instances whose status is OUTDATED.
        public let operationId: String?
        /// Preferences for how CloudFormation performs this stack set operation.
        public let operationPreferences: StackSetOperationPreferences?
        /// A list of input parameters for the stack set template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [Parameter]?
        /// Describes how the IAM roles required for stack set operations are created. You cannot modify PermissionModel if there are stack instances associated with your stack set.   With self-managed permissions, you must create the administrator and execution roles required to deploy to target accounts. For more information, see Grant Self-Managed Stack Set Permissions.   With service-managed permissions, StackSets automatically creates the IAM roles required to deploy to accounts managed by Organizations. For more information, see Grant Service-Managed Stack Set Permissions.
        public let permissionModel: PermissionModels?
        /// The Amazon Web Services Regions in which to update associated stack instances. If you specify Regions, you must also specify accounts in which to update stack set instances. To update all the stack instances associated with this stack set, do not specify the Accounts or Regions properties. If the stack set update includes changes to the template (that is, if the TemplateBody or TemplateURL properties are specified), or the Parameters property, CloudFormation marks all stack instances with a status of OUTDATED prior to updating the stack instances in the specified accounts and Regions. If the stack set update does not include changes to the template or parameters, CloudFormation updates the stack instances in the specified accounts and Regions, while leaving all other stack instances with their existing stack instance status.
        @OptionalCustomCoding<StandardArrayCoder>
        public var regions: [String]?
        /// The name or unique ID of the stack set that you want to update.
        public let stackSetName: String
        /// The key-value pairs to associate with this stack set and the stacks created from it. CloudFormation also propagates these tags to supported resources that are created in the stacks. You can specify a maximum number of 50 tags. If you specify tags for this parameter, those tags replace any list of tags that are currently associated with this stack set. This means:   If you don't specify this parameter, CloudFormation doesn't modify the stack's tags.   If you specify any tags using this parameter, you must specify all the tags that you want associated with this stack set, even tags you've specified before (for example, when creating the stack set or during a previous update of the stack set.). Any tags that you don't include in the updated list of tags are removed from the stack set, and therefore from the stacks and resources as well.   If you specify an empty value, CloudFormation removes all currently associated tags.   If you specify new tags as part of an UpdateStackSet action, CloudFormation checks to see if you have the required IAM permission to tag resources. If you omit tags that are currently associated with the stack set from the list of tags you specify, CloudFormation assumes that you want to remove those tags from the stack set, and checks to see if you have permission to untag resources. If you don't have the necessary permission(s), the entire UpdateStackSet action fails with an access denied error, and the stack set is not updated.
        @OptionalCustomCoding<StandardArrayCoder>
        public var tags: [Tag]?
        /// The structure that contains the template body, with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information, see Template Anatomy in the CloudFormation User Guide. Conditional: You must specify only one of the following parameters: TemplateBody or TemplateURL—or set UsePreviousTemplate to true.
        public let templateBody: String?
        /// The location of the file that contains the template body. The URL must point to a template (maximum size: 460,800 bytes) that is located in an Amazon S3 bucket or a Systems Manager document. For more information, see Template Anatomy in the CloudFormation User Guide. Conditional: You must specify only one of the following parameters: TemplateBody or TemplateURL—or set UsePreviousTemplate to true.
        public let templateURL: String?
        /// Use the existing template that's associated with the stack set that you're updating. Conditional: You must specify only one of the following parameters: TemplateBody or TemplateURL—or set UsePreviousTemplate to true.
        public let usePreviousTemplate: Bool?

        public init(accounts: [String]? = nil, administrationRoleARN: String? = nil, autoDeployment: AutoDeployment? = nil, callAs: CallAs? = nil, capabilities: [Capability]? = nil, deploymentTargets: DeploymentTargets? = nil, description: String? = nil, executionRoleName: String? = nil, managedExecution: ManagedExecution? = nil, operationId: String? = UpdateStackSetInput.idempotencyToken(), operationPreferences: StackSetOperationPreferences? = nil, parameters: [Parameter]? = nil, permissionModel: PermissionModels? = nil, regions: [String]? = nil, stackSetName: String, tags: [Tag]? = nil, templateBody: String? = nil, templateURL: String? = nil, usePreviousTemplate: Bool? = nil) {
            self.accounts = accounts
            self.administrationRoleARN = administrationRoleARN
            self.autoDeployment = autoDeployment
            self.callAs = callAs
            self.capabilities = capabilities
            self.deploymentTargets = deploymentTargets
            self.description = description
            self.executionRoleName = executionRoleName
            self.managedExecution = managedExecution
            self.operationId = operationId
            self.operationPreferences = operationPreferences
            self.parameters = parameters
            self.permissionModel = permissionModel
            self.regions = regions
            self.stackSetName = stackSetName
            self.tags = tags
            self.templateBody = templateBody
            self.templateURL = templateURL
            self.usePreviousTemplate = usePreviousTemplate
        }

        public func validate(name: String) throws {
            try self.accounts?.forEach {
                try validate($0, name: "accounts[]", parent: name, pattern: "^[0-9]{12}$")
            }
            try self.validate(self.administrationRoleARN, name: "administrationRoleARN", parent: name, max: 2048)
            try self.validate(self.administrationRoleARN, name: "administrationRoleARN", parent: name, min: 20)
            try self.deploymentTargets?.validate(name: "\(name).deploymentTargets")
            try self.validate(self.description, name: "description", parent: name, max: 1024)
            try self.validate(self.description, name: "description", parent: name, min: 1)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, max: 64)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, min: 1)
            try self.validate(self.executionRoleName, name: "executionRoleName", parent: name, pattern: "^[a-zA-Z_0-9+=,.@-]+$")
            try self.validate(self.operationId, name: "operationId", parent: name, max: 128)
            try self.validate(self.operationId, name: "operationId", parent: name, min: 1)
            try self.validate(self.operationId, name: "operationId", parent: name, pattern: "^[a-zA-Z0-9][-a-zA-Z0-9]*$")
            try self.operationPreferences?.validate(name: "\(name).operationPreferences")
            try self.regions?.forEach {
                try validate($0, name: "regions[]", parent: name, pattern: "^[a-zA-Z0-9-]{1,128}$")
            }
            try self.tags?.forEach {
                try $0.validate(name: "\(name).tags[]")
            }
            try self.validate(self.tags, name: "tags", parent: name, max: 50)
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case accounts = "Accounts"
            case administrationRoleARN = "AdministrationRoleARN"
            case autoDeployment = "AutoDeployment"
            case callAs = "CallAs"
            case capabilities = "Capabilities"
            case deploymentTargets = "DeploymentTargets"
            case description = "Description"
            case executionRoleName = "ExecutionRoleName"
            case managedExecution = "ManagedExecution"
            case operationId = "OperationId"
            case operationPreferences = "OperationPreferences"
            case parameters = "Parameters"
            case permissionModel = "PermissionModel"
            case regions = "Regions"
            case stackSetName = "StackSetName"
            case tags = "Tags"
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
            case usePreviousTemplate = "UsePreviousTemplate"
        }
    }

    public struct UpdateStackSetOutput: AWSDecodableShape {
        /// The unique ID for this stack set operation.
        public let operationId: String?

        public init(operationId: String? = nil) {
            self.operationId = operationId
        }

        private enum CodingKeys: String, CodingKey {
            case operationId = "OperationId"
        }
    }

    public struct UpdateTerminationProtectionInput: AWSEncodableShape {
        /// Whether to enable termination protection on the specified stack.
        public let enableTerminationProtection: Bool
        /// The name or unique ID of the stack for which you want to set termination protection.
        public let stackName: String

        public init(enableTerminationProtection: Bool, stackName: String) {
            self.enableTerminationProtection = enableTerminationProtection
            self.stackName = stackName
        }

        public func validate(name: String) throws {
            try self.validate(self.stackName, name: "stackName", parent: name, min: 1)
            try self.validate(self.stackName, name: "stackName", parent: name, pattern: "^([a-zA-Z][-a-zA-Z0-9]*)|(arn:\\b(aws|aws-us-gov|aws-cn)\\b:[-a-zA-Z0-9:/._+]*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case enableTerminationProtection = "EnableTerminationProtection"
            case stackName = "StackName"
        }
    }

    public struct UpdateTerminationProtectionOutput: AWSDecodableShape {
        /// The unique ID of the stack.
        public let stackId: String?

        public init(stackId: String? = nil) {
            self.stackId = stackId
        }

        private enum CodingKeys: String, CodingKey {
            case stackId = "StackId"
        }
    }

    public struct ValidateTemplateInput: AWSEncodableShape {
        /// Structure containing the template body with a minimum length of 1 byte and a maximum length of 51,200 bytes. For more information, go to Template Anatomy in the CloudFormation User Guide. Conditional: You must pass TemplateURL or TemplateBody. If both are passed, only TemplateBody is used.
        public let templateBody: String?
        /// Location of file containing the template body. The URL must point to a template (max size: 460,800 bytes) that is located in an Amazon S3 bucket or a Systems Manager document. For more information, go to Template Anatomy in the CloudFormation User Guide. Conditional: You must pass TemplateURL or TemplateBody. If both are passed, only TemplateBody is used.
        public let templateURL: String?

        public init(templateBody: String? = nil, templateURL: String? = nil) {
            self.templateBody = templateBody
            self.templateURL = templateURL
        }

        public func validate(name: String) throws {
            try self.validate(self.templateBody, name: "templateBody", parent: name, min: 1)
            try self.validate(self.templateURL, name: "templateURL", parent: name, max: 1024)
            try self.validate(self.templateURL, name: "templateURL", parent: name, min: 1)
        }

        private enum CodingKeys: String, CodingKey {
            case templateBody = "TemplateBody"
            case templateURL = "TemplateURL"
        }
    }

    public struct ValidateTemplateOutput: AWSDecodableShape {
        /// The capabilities found within the template. If your template contains IAM resources, you must specify the CAPABILITY_IAM or CAPABILITY_NAMED_IAM value for this parameter when you use the CreateStack or UpdateStack actions with your template; otherwise, those actions return an InsufficientCapabilities error. For more information, see Acknowledging IAM Resources in CloudFormation Templates.
        @OptionalCustomCoding<StandardArrayCoder>
        public var capabilities: [Capability]?
        /// The list of resources that generated the values in the Capabilities response element.
        public let capabilitiesReason: String?
        /// A list of the transforms that are declared in the template.
        @OptionalCustomCoding<StandardArrayCoder>
        public var declaredTransforms: [String]?
        /// The description found within the template.
        public let description: String?
        /// A list of TemplateParameter structures.
        @OptionalCustomCoding<StandardArrayCoder>
        public var parameters: [TemplateParameter]?

        public init(capabilities: [Capability]? = nil, capabilitiesReason: String? = nil, declaredTransforms: [String]? = nil, description: String? = nil, parameters: [TemplateParameter]? = nil) {
            self.capabilities = capabilities
            self.capabilitiesReason = capabilitiesReason
            self.declaredTransforms = declaredTransforms
            self.description = description
            self.parameters = parameters
        }

        private enum CodingKeys: String, CodingKey {
            case capabilities = "Capabilities"
            case capabilitiesReason = "CapabilitiesReason"
            case declaredTransforms = "DeclaredTransforms"
            case description = "Description"
            case parameters = "Parameters"
        }
    }
}

// MARK: - Errors

/// Error enum for CloudFormation
public struct CloudFormationErrorType: AWSErrorType {
    enum Code: String {
        case alreadyExistsException = "AlreadyExistsException"
        case cfnRegistryException = "CFNRegistryException"
        case changeSetNotFoundException = "ChangeSetNotFound"
        case createdButModifiedException = "CreatedButModifiedException"
        case insufficientCapabilitiesException = "InsufficientCapabilitiesException"
        case invalidChangeSetStatusException = "InvalidChangeSetStatus"
        case invalidOperationException = "InvalidOperationException"
        case invalidStateTransitionException = "InvalidStateTransition"
        case limitExceededException = "LimitExceededException"
        case nameAlreadyExistsException = "NameAlreadyExistsException"
        case operationIdAlreadyExistsException = "OperationIdAlreadyExistsException"
        case operationInProgressException = "OperationInProgressException"
        case operationNotFoundException = "OperationNotFoundException"
        case operationStatusCheckFailedException = "ConditionalCheckFailed"
        case stackInstanceNotFoundException = "StackInstanceNotFoundException"
        case stackNotFoundException = "StackNotFoundException"
        case stackSetNotEmptyException = "StackSetNotEmptyException"
        case stackSetNotFoundException = "StackSetNotFoundException"
        case staleRequestException = "StaleRequestException"
        case tokenAlreadyExistsException = "TokenAlreadyExistsException"
        case typeConfigurationNotFoundException = "TypeConfigurationNotFoundException"
        case typeNotFoundException = "TypeNotFoundException"
    }

    private let error: Code
    public let context: AWSErrorContext?

    /// initialize CloudFormation
    public init?(errorCode: String, context: AWSErrorContext) {
        guard let error = Code(rawValue: errorCode) else { return nil }
        self.error = error
        self.context = context
    }

    internal init(_ error: Code) {
        self.error = error
        self.context = nil
    }

    /// return error code string
    public var errorCode: String { self.error.rawValue }

    /// The resource with the name requested already exists.
    public static var alreadyExistsException: Self { .init(.alreadyExistsException) }
    /// An error occurred during a CloudFormation registry operation.
    public static var cfnRegistryException: Self { .init(.cfnRegistryException) }
    /// The specified change set name or ID doesn&#39;t exit. To view valid change sets for a stack, use the ListChangeSets operation.
    public static var changeSetNotFoundException: Self { .init(.changeSetNotFoundException) }
    /// The specified resource exists, but has been changed.
    public static var createdButModifiedException: Self { .init(.createdButModifiedException) }
    /// The template contains resources with capabilities that weren&#39;t specified in the Capabilities parameter.
    public static var insufficientCapabilitiesException: Self { .init(.insufficientCapabilitiesException) }
    /// The specified change set can&#39;t be used to update the stack. For example, the change set status might be CREATE_IN_PROGRESS, or the stack status might be UPDATE_IN_PROGRESS.
    public static var invalidChangeSetStatusException: Self { .init(.invalidChangeSetStatusException) }
    /// The specified operation isn&#39;t valid.
    public static var invalidOperationException: Self { .init(.invalidOperationException) }
    /// Error reserved for use by the CloudFormation CLI. CloudFormation doesn&#39;t return this error to users.
    public static var invalidStateTransitionException: Self { .init(.invalidStateTransitionException) }
    /// The quota for the resource has already been reached. For information about resource and stack limitations, see CloudFormation quotas in the CloudFormation User Guide.
    public static var limitExceededException: Self { .init(.limitExceededException) }
    /// The specified name is already in use.
    public static var nameAlreadyExistsException: Self { .init(.nameAlreadyExistsException) }
    /// The specified operation ID already exists.
    public static var operationIdAlreadyExistsException: Self { .init(.operationIdAlreadyExistsException) }
    /// Another operation is currently in progress for this stack set. Only one operation can be performed for a stack set at a given time.
    public static var operationInProgressException: Self { .init(.operationInProgressException) }
    /// The specified ID refers to an operation that doesn&#39;t exist.
    public static var operationNotFoundException: Self { .init(.operationNotFoundException) }
    /// Error reserved for use by the CloudFormation CLI. CloudFormation doesn&#39;t return this error to users.
    public static var operationStatusCheckFailedException: Self { .init(.operationStatusCheckFailedException) }
    /// The specified stack instance doesn&#39;t exist.
    public static var stackInstanceNotFoundException: Self { .init(.stackInstanceNotFoundException) }
    /// The specified stack ARN doesn&#39;t exist or stack doesn&#39;t exist corresponding to the ARN in input.
    public static var stackNotFoundException: Self { .init(.stackNotFoundException) }
    /// You can&#39;t yet delete this stack set, because it still contains one or more stack instances. Delete all stack instances from the stack set before deleting the stack set.
    public static var stackSetNotEmptyException: Self { .init(.stackSetNotEmptyException) }
    /// The specified stack set doesn&#39;t exist.
    public static var stackSetNotFoundException: Self { .init(.stackSetNotFoundException) }
    /// Another operation has been performed on this stack set since the specified operation was performed.
    public static var staleRequestException: Self { .init(.staleRequestException) }
    /// A client request token already exists.
    public static var tokenAlreadyExistsException: Self { .init(.tokenAlreadyExistsException) }
    /// The specified extension configuration can&#39;t be found.
    public static var typeConfigurationNotFoundException: Self { .init(.typeConfigurationNotFoundException) }
    /// The specified extension doesn&#39;t exist in the CloudFormation registry.
    public static var typeNotFoundException: Self { .init(.typeNotFoundException) }
}

extension CloudFormationErrorType: Equatable {
    public static func == (lhs: CloudFormationErrorType, rhs: CloudFormationErrorType) -> Bool {
        lhs.error == rhs.error
    }
}

extension CloudFormationErrorType: CustomStringConvertible {
    public var description: String {
        return "\(self.error.rawValue): \(self.message ?? "")"
    }
}
